Posted by: Kaushal on: July 16, 2008
In one of my previous blog post, I Described about Mutually Exclusive CheckBox inside GridView.
In this example, there is a “Select All” checkbox in header to select/deselect all the checkboxes inside GridView. MoreOver, if user select all the checkboxes manually one by one, then header checkbox should automatically be selected and vice versa.
Here is the Scenario; There is one TemplateColumn in GridView which is used to Select Row within GridView. So, There will be CheckBox inside ItemTemplate of that TemplateColumn. User would be able to select more than one CheckBox in that Column. And to Select All the CheckBoxes of that colum, There will be a “Select All” CheckBox in HeaderTemplate of that GridView. When user check “Select All” CheckBox in Header, all the checkboxes should be selected and vice versa.
July 25, 2008 at 6:59 am
hi Kaushal, i have gone through your blog of select header checkbox in grid when checkboxes in each of the row is selected, Its a Great stuff , Helped me when i stuked in it. but there is one problem it is not working when there is only one row is in the grid… when we select checkbox in first row headrer checkbox is not getting selected . . .
can you help me out????
- Dhwanil