0

I have a requirement to add cssClass for nested child rows. I can add class for parent row but how to add nested child rows.

this.dataGrid.rows[i].cssClass
indu
  • 1,057
  • 2
  • 9
  • 15

1 Answers1

1

You need to add an event handler for the formatItem event of FlexGrid and then iterate over all the rows and set their cssClass property.

JS:

grid.formatItem.addHandler((s, e) => {
    s.rows.forEach(r => {
        r.cssClass = 'custom-back';
    })
});

CSS:

.custom-back {
  background: rgb(18, 148, 148) !important;
}
assax24
  • 171
  • 5