Code Snippet posted by:
Santosh0683 | Posted on: 8/22/2010 | Category:
ASP.NET Codes | Views: 2919 | Status:
[Member] |
Points: 40
|
Alert Moderator
protected void gv_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
DataRow pr = ((DataRowView)e.Row.DataItem).Row;
if (pr["IsActive"].ToString() == "True")
{
e.Row.ForeColor = System.Drawing.Color.Red;
e.Row.Attributes.Add("onmouseout", "this.style.backgroundColor='#f7fff8';");
e.Row.ToolTip = "Your a/c has been denied!";
}
else
{
e.Row.ForeColor = System.Drawing.Color.Blue;
}
}
}
Santosh Singh
http://aspdotnetcode.blogspot.in/
Found interesting? Add this to: