or
void rGridViewTasks_ViewCellFormatting(object sender, CellFormattingEventArgs e)
{
if (e.CellElement.ColumnInfo.Name == "Priority")
{
//if ((DateTime)e.CellElement.RowInfo.Cells["TargetDt"].Value >= DateTime.Now )
//{
// e.CellElement.BackColor = Color.DarkRed;
// e.CellElement.Value = "1";
//}
//else if (((DateTime)e.CellElement.RowInfo.Cells["WarningDate"].Value >= DateTime.Now) &&
// ((DateTime)e.CellElement.RowInfo.Cells["TargetDt"].Value < DateTime.Now))
//{
// e.CellElement.BackColor = Color.DarkOrange;
// e.CellElement.Value = "2";
//}
//else
//{
// e.CellElement.BackColor = Color.DarkGreen;
// e.CellElement.Value = "3";
//}
}
}