Creating a Select/Deselect all checkbox in a datagrid

  • Thread starter Thread starter VBNovice05
  • Start date Start date
V

VBNovice05

I run a search on my database and get items that fit that search in a
datagrid. There are checkboxes already for each item. I need to
create a select/deselect all checkbox at the top of the column and be
able to select.deselect all items that I have found. I am using C#.Net

Thanks in advance for this
 
something like this.

foreach ( DataGridItem item in DataGrid1.Items )
{
CheckBox _Box = item.FindControl("myCheck");
_Box.Checked = true;
}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top