Hi Richard,
Thank you for your patience.
Issue 1:
how to format text color in one cell based on a value in a different cell in the same row.You can able to set the text color in one cell based on a value in another cell in the same row when clicking the Apply Conditions button by using GridGroupingControl1 QueryCellStyleInfo event. The following code snippet is used to achieve this behavior:
protected void GridGroupingControl1_QueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e)
{
if (Buttonclick == 1)
{
if (e.TableCellIdentity.RowIndex > 3)
{
if (e.TableCellIdentity.ColIndex == 6)
{
FirstCellValue = e.Style.CellValue.ToString();
}
if (e.TableCellIdentity.ColIndex == 7)
{
SecondCellValue = e.Style.CellValue.ToString();
}
if (FirstCellValue.ToString().Length > 0 && SecondCellValue.ToString().Length > 0)
{
if (Convert.ToDouble(FirstCellValue) > Convert.ToDouble(SecondCellValue))
{
if (e.TableCellIdentity.ColIndex == 7)
{
e.Style.TextColor = Color.Red;
}
}
}
}
}
}
Please refer the sample in the below link which illustrates the above:
http://websamples.syncfusion.com/samples/Grid.Web/6.1.0.34/72077/main.htm Please try running the above sample and let me know if this helps.
Regards,
Vishnu.