format
Sets the data format.
Type
One of the format constants below:
|
date display |
|
number display |
|
text display |
|
fraction display |
|
locale-adapting currency display |
| To format cells or columns of a Table, use the tableLens property. |
For the Date, Decimal, and Message formats, use the formatSpec property to assign a format specification using the appropriate masks.
Example
// Number format
format = StyleConstant.DECIMAL_FORMAT;
formatSpec = "#,###.00";
// Text format
format = StyleConstant.MESSAGE_FORMAT;
formatSpec = "{0} Inc."
|
Either syntax below can be used in component script:
For onInit/onRefresh scripts, and for component and property scripts on other components, the second (qualified) form is required. |