I have a gridview that i need to highlight certain records that meet the criteria.
I was trying this logic within the RowDataBound event but it highlights the entire gridview
foreach (DataRow row in RequisitionList.Rows)
{
Decimal.TryParse(row["Total"].ToString(), out reqTotal);
if (reqTotal > appRate)
{
e.Row.BackColor = Color.Red;
}
}
I just want the row that meets the if condition to be highlighted in red.
What did i do wrong?
...
Go to the complete details ...