c# - After Refresh(F5) the Page the Check's CheckChanged event is not fired,the Check is child control of Gridview -
On my page I have 3 gridview controls. In each grid I am using the check box as a templatefile. When I'm selecting the first grid check box. It displays some records. At this time when I press the F5 (refresh) button. All events have not been removed in the page.
The check box in the grid:
& lt; Asp: GridView id = "gvSelectQuest" runat = "server" AutoGenerateColumns = "False" Allow = "True" onrowdatabound = "gvQuestion_RowDataBound" & gt; & Lt; Columns & gt; & Lt; Asp: TemplateField HeaderText = "Select" & gt; & Lt; Itemmetlet & gt; & Lt; ASP: Checkbox ID = "chkSelectGrp" AutoPostback = "True" On Checked Change = "Check Changed" Runat = "Server" /> & Lt; / ItemTemplate & gt; & Lt; / ASP: TemplateField & gt; & Lt; ASP: BoundfieldDefined = "_ quest_AdminID" header text = "admin" /> & Lt; / Column & gt; & Lt; / ASP: GridView & gt; check box event:
public zero check-changel (object sender, event_arigues e) {check box chk = (checkbox) (sender); Foreach (GridViewRow rowItem in gvQues group.Rows) {}} Please help me anybody.
Use this for the checkbox in itemTemplate to fire the incident,
Pre> & lt; ASP: check box ID = "chkQuest" runat = "Press F5 to trigger server" Onked change = "check changed" AutoPostback = "True" />
Comments
Post a Comment