Skip to main content
OutSystems

How to style a row of totals in a Table Record

Question

How do I make the last row of totals in a Table Record look visually distinct?

In the example below:

  • How to I make the last row bold?
  • How do I add an empty row above the last row?

image001.png@01D0C489.0D665BC0

Answer

Use the Extended Properties to assign your own CSS class to the last row of the Table Record widget.

Use the action ListInsert from the System eSpace to add an empty row to a list, but remember to be consistent.

Start by creating your own CSS class. On the example below, the class 'LastTableRow' specifies bold text on a text line 50 pixels high.

Then, use the Extended Properties of rows to add CSS classes to every row. On the example below, the expression:

  • Assigns the CSS class 'LastTableRow' to the last row. This would be the row where the Current Row Number equals Length-1, because Length starts at 0.
  • Assigns no CSS class to the other rows.

On the example below, the action ListInsert modifies the Aggregate Computers.

  • Use an empty local variable of the same type as the list to add an empty line.
  • Specify the position as Length-1 to add an element before the last element of the list.

However, remember to be consistent and also add the row every time you use the Refresh widget.