Demos
Documentation
API
More Samples
Download Wijmo

Row Styling

By default, the grid adds a 'wj-alt' class to every other row, and the 'wijmo.css' file uses this class to style alternating rows. You can disable this using some custom CSS, but it is often easier just to set the grid's showAlternatingRows property to false if you don't want alternating row styles applied at all.

The FlexGrid re-generates rows whenever the data source refreshes, which happens when the data is sorted, filtered, grouped, or edited. Because of this, you should not expect row properties to retain their values in most cases.

If you do want to apply custom styles to rows, you should do this when handling the loadedRows event, which fires whenever the grid re-generates the rows.

The row properties that affect styling are:

  • cssClass: Specifies a class name to be added to cells in this row. The class name can be used in CSS rules to modify the style of cells in this row.
  • height: Height, in pixels, of the row.

This grid shows the effect of the grid's showAlternatingRows and the row's cssClass properties: