05-29-2020 06:48 AM
For my GUI I want to display final numbers in a format the user is used to seeing them in. I know 1M is the same as 1000k, but some people, well, they just don't. Is there a quick way to do this? I know I can format into string and do some syntax, but was hoping I could do it somehow in the numeric indicators properties. The indicators are all clustered and it will be a pain to go through and add a format into string for each indicator.
05-29-2020 07:42 AM - edited 05-29-2020 07:42 AM
You can set your display format to something like %#fk and do the math to convert your value into k.
05-29-2020 09:24 AM
Interesting. I'd really like there to be some "avoid decimal SI" or "long SI" of whatever it should be called. Even though 1.234M is the same as 1234k i prefer the latter. It's really only in the 1-10 range of an exponent this is relevant, as 0.123M will be written as 123k.
05-29-2020 09:59 AM
Yeah it doesn't seem like there is a quick way to do this through the indicator properties as I was hoping. Would be nice to "coerce" the SI unit though.
05-29-2020 11:16 AM - edited 05-29-2020 11:18 AM
Could you do with with units somehow? Think you could have a control with the units of "m" for meter, and also units of "km" for kilometer.
There you could show 1000 with units of km outside.
Can that transfer to units of kilo______ where you shows a unitless base number? (no distance, volume, speed, .... just a numeric value, but allows you to add the prefixes of k, M, whatever?)
In other words, you get the benefit of using units and their accompanying prefixes, without having to use specific unit itself?
05-29-2020 12:06 PM
I doubt this is easier than formatting the strings manually, but you could always make an XControl or QControl to do the work for you.