cellFormat

Table Properties for general information about the Table component.

Specifies the Table cell data format as a two dimensional array. The attribute can be referenced using the row number as the first index and the column header or number as the second index, [row][col]. Column and row indices start at 0.

Type

Array

Two-dimensional array of formats. See Add Data Format for information on how to specify formats.

StyleConstant.DATE_FORMAT

date display

StyleConstant.DECIMAL_FORMAT

number display

StyleConstant.MESSAGE_FORMAT

text display

StyleConstant.PERCENT_FORMAT

fraction display

StyleConstant.CURRENCY_FORMAT

locale-adapting currency display

Example

cellFormat[5][3] = [StyleConstant.DATE_FORMAT, "yy-MMMM-dd"];
cellFormat[2]['Total'] = [StyleConstant.DECIMAL_FORMAT, "#,###.00"];

Either syntax below can be used in component script:

cellFormat                 // unqualified
TableView1.cellFormat      // qualified

For onInit/onRefresh scripts, and for component and property scripts on other components, the second (qualified) form is required.