后台代码:
for (int i = 0; i < this.GvCourses.Rows.Count; i++)
{
CheckBox chb = this.GvCourses.Rows[i].FindControl("CheckB") as CheckBox;
if (chb.Checked)
{
strDelete += "," + this.GvCourses.Rows[i].Cells[0].Text;
}
}
前台代码:
<asp:CheckBox runat="server" ID="CheckB" />
原文:http://www.cnblogs.com/lanke0/p/5720269.html