Here is what i am doing right now.
private void gvOrderList_RowStyle(object sender, RowStyleEventArgs e)
{
GridView View = sender as GridView;
if (e.RowHandle >= 0)
{
string sGridRecordOrderNumber = View.GetRowCellDisplayText(e.RowHandle, View.Columns["orderNo"]);
foreach (string sNewRecordOrderNo in oNewRecordOrderNoList)
{
if (sGridRecordOrderNumber == sNewRecordOrderNo)
{
e.Appearance.BackColor = Color.Salmon;
e.Appearance.BackColor2 = Color.SeaShell;
break;
}
}
}
}
I fire sql queries every 30 seconds using thread and give datasource as a list. oNewRecordOrderNoList contains my new record list. I am matching it's OrderNo column with the handle's same column to get highlighted rows.
I am getting my rows highlighted as expected but also getting A BIG CROSS over my gridcontrol for 1 second. And if i open other forms after the current one, it also shows cross in other forms. LOOKS QUITE UGLY.
I want a solution to remove this cross or another solution by which i can change appearance of my new rows by matching column values WITHOUT A CROSS DISPLAY.
A help would be appreciated.