title: Control in UpdatePanel loses value
body: <p>I have two comboboxes, first one triggers updatepanel that updates second one:</p>
  
  <pre><code>        protected void cb1_SelectedIndexChanged(object sender, EventArgs e)
          {
  
          cb2.DataSource = DT1;
          cb2.DataBind();
  
  
           }
  </code></pre>
  
  <p>Problem is, when I click button, all values are ok, except one in UpdatePanel, so updatepanel somehow resets selected index on child controls.</p>
  
  <p>Any idea how to fix this?</p>
  
  <p>I know about sessions, but I don't know on what step to assign value of cb2 to session.</p>
  
  <p>Thanks.</p>
  
  <p>Update, aspx</p>
  
  <pre><code>    &lt;asp:UpdatePanel ID="UpdatePanel1" runat="server" ChildrenAsTriggers="False" 
                                                          UpdateMode="Conditional"&gt;
      &lt;dx:ASPxComboBox ID="cb2" runat="server" Height="22px" ValueField="ID" 
                                                                  ValueType="System.Int32" Width="170px"&gt;
                                                                  &lt;Columns&gt;
                                                                      &lt;dx:ListBoxColumn Caption="ID" FieldName="ID" Visible="False" /&gt;
                                                                      &lt;dx:ListBoxColumn Caption="City" FieldName="City" /&gt;
                                                                  &lt;/Columns&gt;
                                                              &lt;/dx:ASPxComboBox&gt;
  &lt;/ContentTemplate&gt;
                                                      &lt;Triggers&gt;
                                                          &lt;asp:AsyncPostBackTrigger
      ControlID="cb1" EventName="SelectedIndexChanged" /&gt;
                                                          &lt;/Triggers&gt;
                                                      &lt;/asp:UpdatePanel&gt;
  </code></pre>