Zum Inhalt springen

Number format: decimal and thousands separator

Every user chooses their own number format. Always format numbers the way the user prefers.

Video · 0:481Tool API

The user settings contain a number_format object. Read it before you display any number and format accordingly.

The video loads from Loom when you start it.

Read transcript
  1. Each user has his own number format, so he can decide on the thousand separator between dot, comma, and nothing and on the comma separator between dot and a comma.
  2. So for example for me this is the best solution. As a thousand separator I have the dots and a comma for the decimal separator and when I save it and I get at the user settings there are two new fields which are decimal separator and thousand separator.
  3. So please all the number formats you have to check the user settings what is preferred for him, the decimal or thousand separator and then show the the number in this format.
GET /suite/api/user-settings

"number_format": {
  "decimalSeparator": ",",
  "thousandsSeparator": "."
}
Stuck?Our developers are happy to help – support@koerbler.com
Email us