title: ASP.NET Binding DropDownList throwing error
body: <p>I'm trying to bind an <code>asp:DropDownList</code> but I keep getting an error</p>
  
  <blockquote>
    <p>An exception of type 'System.Web.HttpException' occurred in
    System.Web.dll but was not handled in user code</p>
    
    <p>Additional information: DataBinding: 'System.Data.DataRowView' does
    not contain a property with the name 'id_enabled'</p>
  </blockquote>
  
  <p>Here is my <code>SqlDataSource</code> </p>
  
  <pre><code>&lt;asp:SqlDataSource 
      ID="sql_enabled_ddl" 
      runat="server" 
      ConnectionString="&lt;%$ ConnectionStrings:Tip-Tour %&gt;"  
  
      SelectCommand ="SELECT 
                          id_enabled, 
                          description
  
                      FROM
                      (
                          SELECT 
                              1 AS id_enabled,
                              'true' AS description
  
                           UNION 
  
                           SELECT 
                              2 AS id_enabled,
                              'false' AS description
  
                      ) AS passport_enabled"&gt;
  
  &lt;/asp:SqlDataSource&gt;
  </code></pre>
  
  <p>and my DropDownList</p>
  
  <pre><code>&lt;asp:DropDownList
      ID="DropDownList2"
      runat="server"
      DataSourceID="sql_enabled_ddl"
      DataTextField="description"
      DataValueField="id_enabled"
      SelectedValue='&lt;%# Bind("id_enabled") %&gt;' 
      Width="87%"&gt;
  &lt;/asp:DropDownList&gt;     
  </code></pre>