Float number, limit decimal chars

Dear Sirs,

Have we a way of limiting the amount of characters on the right side of the comma on a Float number?
Like a round(), it would be usefull.

Kind Regards

Yes, but its a math expression, not a tool. I don´t know if there´s a easier way, but I use the trick to multiply for 10,100,1000 etc depending the decimals you want, make floor of that and then divide again for the same value. For example, 3 digits after comma in #SWES#
(floor(#SWES#*1000)/1000)

3 Likes

im gessing thats valid :wink:
Thank you for your help, i will test and reply

1 Like

I was searching for a way to limit the decimal places on the latitude and longitude tags. I tried your expression but multiplied and divided by 100,000 instead of your example. It worked perfect for a 5 place decimal return on the position. And that’s tested on a TicWatch E which tends to not like complicated expressions. ( Which is the reason I have one just for testing purposes. :smiley:)

1 Like