ASP PostBack not posting all controls

Meretreta

New Member
I have an ASP page that contains a DDL tied to a select query and gridview. After pageLoad I can select a value and populate the gridview with no issues. \[code\] <asp:DropDownList ID="DropDownList3" runat="server" OnSelectedIndexChanged="DropDownList3_SelectedIndexChanged" AutoPostBack="True"> <asp:ListItem>Select an entry</asp:ListItem> <asp:ListItem>Requested</asp:ListItem> <asp:ListItem>Requested and Closed</asp:ListItem> <asp:ListItem>Ordered</asp:ListItem> <asp:ListItem>Working</asp:ListItem> <asp:ListItem>Warranty Parts</asp:ListItem> <asp:ListItem>Warranty Service</asp:ListItem> <asp:ListItem>Filled</asp:ListItem> </asp:DropDownList>\[/code\]Inside the gridview I have an item template containing another DDL which triggers an update query on that row. \[code\] <asp:DropDownList ID="DropDownList4" runat="server" DataSourceID="SqlDataSource1" DataTextField="DDvalue" DataValueField="code" Height="20px" Width="150px" AutoPostBack="True" CommandName="DD4" OnSelectedIndexChanged = "DDL4_SelectedIndexChanged"> </asp:DropDownList> \[/code\]Both DDLs are set up for AutoPostBack. The issue is that when the OnSelectedIndexChanged event is tripped from DropDownList4 it does not bring the page back to the results of DropDownList3. In otherwords the databind of the Gridview that happens in the Pageload event is apparently null.\[code\] if (!IsPostBack) this.DataBind(); \[/code\]How can I get the page to refresh the gridview on each modification?
 
Back
Top