foreach (GridViewRow row in gvPrivileges.Rows)
{
foreach (TableCell cell in row.Cells)
{
CheckBox chkBox = cell.FindControl("chkRoleId") as CheckBox;
if (chkBox != null)
{
if (chkBox.Checked == true)
{
if (!listRoles.Contains(int.Parse(chkBox.ToolTip)))
{
listRoles.Add(int.Parse(chkBox.ToolTip));
}
}
}
}
}
No comments:
Post a Comment