Some actions from the Formatter add-on lets you provide a custom number format. Here are a few examples of the formats you can use:
| Format | Result |
|---|---|
| #,###.00 | 1,234.56 |
| #.###,00 | 1.234,56 |
| #.0 | 1234.5 |
| #.0000 | 1234.5678 |
| $ #,###.00 | $ 1,234.56 |
| #.###,00€ | 1.234,56€ |
| #,### | 1,234 |
| # | 1234 |
Supported formats
The number format supports the character # for the integer part and the character 0 for the fractional part:
| Format | Description | Example |
|---|---|---|
| # | The integer part without separator | 1000000 |
| #,### | The integer part with separator | 1,000,000 |
| 0 | The fractional part without separator and 1 decimal (The number of 0s define the number of decimals) | 1 |
| .00 | The fractional part with separator and 2 decimals | .11 |
| .0000 | The fractional part with separator and 4 decimals | .1111 |
| #,###.00 | Number with separators and 2 decimals | 1,000,000.11 |
In addition you can add prefixes and sufixes to the number format.
| Format | Description | Example |
|---|---|---|
| $#,###.00 | Number with a prefix | $1,000,000.11 |
| $ #,###.00 | Number with a prefix separated | $ 1,000,000.11 |
| Total: #,###.00 | Number with letters as prefix | Total: 1,000,000.11 |
| #,###.00€ | Number with a sufix | 1,000,000.11€ |
| #,###.00 € | Number with a sufix separated | 1,000,000.11 € |
| #,###.00 to pay | Number with letters as sufix | 1,000,000.11 to pay |
Negative numbers
The number format will keep negative numbers adding the minus symbol to the formatted value:
| Format | Result |
|---|---|
| #,###.00 | -1,234.56 |
| #.0 | -1234.5 |
| $ #,###.00 | $ -1,234.56 |
| #.###,00€ | -1.234,56€ |