vendredi 27 mars 2015

how can i set checkbox in header template in gridview? inc# side

I want to change the checkbox value in grid view in cs code not in asp.net side? How can i set the it?


I tried it



while (reader.Read())
{
foreach (TableCell headerCell in GridView1.HeaderRow.Cells)
{
// or access Controls with index
// headerCell.Controls[INDEX]
headerCell.FindControl("c") as CheckBox = true;

}
}




Aucun commentaire:

Enregistrer un commentaire