Space instead of Comma in NumberFormat

Hello,

is there a way to have this format but with space instead of comma? (It is in the column definition on table)
image image

None of these works
image

I know I can manually type the format there but it doesnt work the way I expected. Am I missing something?
image image

The only way I was able to walk around it is by creating a Script to change number to string with spaces but I donť think it is the best practice.

Thank you for help.

If I'm not mistaken, the number formatting in the perspective table uses Numeral.js.
I'd start by checking there if there's a way to do this, but I'm afraid there is not.

edit: There's a way to register custom formats, but it requires running javascript. So I guess you could find a way to inject js to run this... but it's probably not better than running your own formatting script - except for the fact that your column now contains strings and it messes up sorting.
Or make a custom module to register new formats.

edit again: I can't remember where I found this numeral.js thing... looking for it now, I find references to this instead: DecimalFormat (Java SE 11 & JDK 11 )

Number formatting in Ignition is largely driven by Java's DecimalFormat class. See the DecimalFormat documentation for more information.

So I'm not sure about anything.

The , is just a standin for the delimitor, it doesnt litterly mean ','
The delimitor should be defined by the locale

1 Like

But what if you don't want your locale's default separator ?

Then you use strings i guess :man_shrugging:

1 Like