or
for
(int i = 0; i <= gviewTasks.MasterTableView.Items.Count - 1; i++)
{
//GridViewRow gvr= new GridViewRow();
LinkButton lnkbtnusername = new LinkButton();
lnkbtnusername = (
LinkButton)(gviewTasks.MasterTableView.Items[i].Cells[0].FindControl("Link"));
lnkbtnusername.Text = gviewTasks.MasterTableView.Items[i].Cells[3].Text.ToString();
if (gviewTasks.MasterTableView.Items[i].Cells[3].Text.ToString().Trim().ToLower() == "leave")
{
lnkbtnusername.ForeColor = System.Drawing.
Color.Black;
}
else
{
lnkbtnusername.ForeColor = System.Drawing.
Color.Blue;
}
}
| Me.ChkMath.DataSource = dsBlocMath |
| Me.ChkMath.DataTextField = "NOM_COURS" |
| Me.ChkMath.DataValueField = "ID_COURS" |
| Me.ChkMath.DataBind() |
| <asp:CheckBoxList ID="ChkMath" runat="server"> |
| </asp:CheckBoxList> |