Formats text found in a column in the provided table.
TableFormat(Table, Column Index, Format)
Where:
Table is the table in which to perform the formatting.
Column Index is the column in which to perform the formatting.
Format is an Excel formatting string, for example:
Regional Culture
This function uses the regional culture of the device running a specification to format the output.
For example the rule:
TableFormat(DwLookupTable,2,"hh:mm:ss")
Will return 11:05:25 for some regional cultures.
And 11.05.25 for other regional cultures.
To format text in a table using the invariant culture see TableFormatInvariant.
| Rule | Meaning |
|---|---|
| TableFormat(DWLookupCurrency,4,"MMM-YY") | Will return an array from the table Data, with the values in column 4 formatted as a date. See Example Outcome 1 below. |
| TableFormat(DWLookupCurrency,3,"0.0%") | Will return an array from the table Data, with the values in column 3 formatted as a percentage. See Example Outcome 2 below. |
Currency Table
| Country | Currency | Rate | Date |
|---|---|---|---|
| France | Euro | 1.3 | 29/03/15 |
| United States | Dollar | 1.4 | 18/02/15 |
| Germany | Euro | 1.3 | 22/01/15 |
| United Kingdom | Pound | 1 | 15/07/14 |
Currency Table
| Country | Currency | Rate | Date |
|---|---|---|---|
| France | Euro | 1.3 | Mar-15 |
| United States | Dollar | 1.4 | Feb-15 |
| Germany | Euro | 1.3 | Jan-15 |
| United Kingdom | Pound | 1 | Jul-14 |
DriveWorks will return the table above as an array, which will look like:
| Table returned as an Array |
|---|
| {"Country","Currency","Rate","Date";"France","Euro","1.3","Mar-15";"United States","Dollar","1.4","Feb-15";"Germany","Euro","1.3","Jan-15";"United Kingdom","Pound","1","Jul-14"} |
Currency Table
| Country | Currency | Rate | Date |
|---|---|---|---|
| France | Euro | 1.3% | 29/03/15 |
| United States | Dollar | 1.4% | 18/02/15 |
| Germany | Euro | 1.3% | 22/01/15 |
| United Kingdom | Pound | 1.0% | 15/07/14 |
DriveWorks will return the table above as an array, which will look like:
| Table returned as an Array |
|---|
| {"Country","Currency","Rate","Date";"France","Euro","1.3%","29/03/2015";"United States","Dollar","1.4%","18/02/2015";"Germany","Euro","1.3%","22/01/2015";"United Kingdom","Pound","1.0%","15/07/2014"} |