I have a dropdown list which is in updatepanel. I have to fill that dropdown on a client event through javascript which calls __dopostback of the updatepanel and calls its load event.
Problem is that when i submit the form updatepanel_Load event also execute again and it again reset the DropDownLIst which causes the loss of selectedValue in Dropdown.
<asp:UpdatePanel ID="UpdatePanel3" runat="server" OnLoad="UpdatePanel3_Load" UpdateMode="Conditional">
<ContentTemplate>
<asp:DropDownList ID="ddlItems" runat="server" CssClass="dropdown">
</asp:DropDownList>
</ContentTemplate>
</asp:UpdatePanel>
On page Load this dropdown is Empty .... no funtion to fill it.
Now the problem is when ever I Fill the Dropdown throught Load of UPatepanel, that UPdatepanel Load event also execute when I submit my page. Actually the solution of javascript is due to a table and on Selection of the table row item it Fills the DropDownList from __dopostback of my updatepanel.
I have button which opens a popup window and that popup window contains a table, when client select some item from that table and close that popup window then I fill my dropdown (in parent or opener page through Ajax, Updatepanel's Load) as further selction option. so dropdown databind is dependent on that tables input.