How to change the background color of a row in sfDataGrid.

Good Day,

Is there a way to change the background color of a row in sfDatagrid in the code behind not in xaml. When a data has the same number it has the same color.

Thank you and More power.

Regards,
Bryce

1 Reply

SR Sivakumar R Syncfusion Team December 2, 2015 07:06 PM UTC

Hi Bryce,

You can apply style to SfDataGrid rows using SfDataGrid.RowStyle and SfDataGrid.RowStyleSelector properties by creating style for VirtualizingCellsControl.  Refer the below KB for more information,
https://www.syncfusion.com/kb/3176/

Either you can use StyleSelector or change the Background property using Converter in code behind to achieve your requirement

Thanks,
Sivakumar

Loader.
Up arrow icon