title: Retain Selected Value of dynamically bound dropdownlist after postback
body: <p>I have a dropdownlist which I declare on the aspx markup like so:</p>
  
  <pre><code>&lt;asp:DropDownList ID="State" runat="server"&gt;&lt;/asp:DropDownList&gt;
  </code></pre>
  
  <p>Then I bind it on page load like so :</p>
  
  <pre><code>protected void Page_Load(object sender, EventArgs e)
      {
         BindDropdowns();
      }
  private void BindDropdowns()
      {
          State.DataSource = DataAccess.GetStates();
          State.DataValueField = "FieldId";
          State.DataTextField = "FieldName";
          State.DataBind();
      }
  </code></pre>
  
  <p>The selected value is not retained after postback, I also cannot fire the selectedindexchangedevent. What's wrong ?</p>