BoldSignA modern eSignature application with affordable pricing. Sign up today for unlimited document usage!
Hi Ari,
Thank you for contacting Syncfusion support.
We have analyzed your query and you can achieve your requirement by handling QueryCellInfo event, within this event you can set the Background for selected row by using GridDataControl.Model.Options.HighlightSelectionBackground property. For your refer we have attached the sample in the below sample link, please refer it.
public MainWindow() { InitializeComponent(); grid.Loaded += grid_Loaded; }
void grid_Loaded(object sender, RoutedEventArgs e) { this.grid.Model.QueryCellInfo += Model_QueryCellInfo; }
void Model_QueryCellInfo(object sender, GridQueryCellInfoEventArgs e) { if (e.Style.RowIndex > 0) { var column = this.grid.VisibleColumns["EmployeeID"]; int index = this.grid.VisibleColumns.IndexOf(column); var visiablecolumnindex= this.grid.Model.ResolveVisibleColumnIndexToPosition(index); var cell = this.grid.Model[e.Style.RowIndex, visiablecolumnindex].CellValue; var result = Convert.ToInt32(cell); if (result % 3 == 0) { this.grid.Model.Options.HighlightSelectionBackground = Brushes.Green; } else e.Style.Enabled = false; } } |
Sample link: http://www.syncfusion.com/downloads/support/forum/119383/ze/BackgroundColor1819005304
Please let us know if you require further assistance on this.
Thanks,
Ashok
Hi Ari,
Thank you for update.
We have analyzed your query but we are unable to understand your requirement clearly. In our previous update itself we have highlight the whole row based on the cell value only. Could you please share more details regarding your requirement, that would be more helpful for further analyze.
Please let us know if you require further assistance.
Thanks,
Ashok