I want to to bind the entire row’s background with a boolean property for each record in XAML.
There are too many ways to change datagrid’s style but I want to change the specific style that is responsible for the entire row…
For example, the class Record is the bound data behind the datagrid and it has a boolean property “Correct” (true / false), I’d like the datagrid to show the row with false Correct in red background, green when true.
I tried to use CellStyle but it only changes the background in each cell in the row, not the whole row.
As mentioned use DataGrid.RowStyle, for example: