title: ASP.NET Drop Down List error with null values in SqlDataSource
body: <p>I have a drop down list on a form view which are both bound to different data sources.</p>
  
  <p>When trying to run the program I am getting 'ddlFieldName' has a SelectedValue which is invalid because it does not exist in the list of items.  Parameter name: value.</p>
  
  <p>I think it is because the field associated with the drop down list contains a null value which isnt in the referencing table.  I have tried to work round this by adding an empty item in the list but it doesnt seem to be working:</p>
  
  <pre><code>&lt;asp:DropDownList ID="ddlAgency" runat="server" 
  DataSourceID="dsAgency" DataTextField="Agency" 
  DataValueField="AgencyID" SelectedValue='&lt;%# Bind("Agency") %&gt;'  &gt;
  &lt;asp:ListItem&gt;&lt;/asp:ListItem&gt;&lt;/asp:DropDownList&gt;
  </code></pre>
  
  <p>Can anyone suggest a way round this?</p>
  
  <p>Thanks</p>
  
  <p>anD666</p>