Universal Robots Forum

Decimal precision with InputTextField

I need to insert numbers like 0.0057 but the InputTextField round it to 0.006.
Is there a way to set the decimal precision for an InputTextField?

I’m using html input with type=“number”.
I’ve made some test with the property step, for example step=“0.0001” or step=“any” but it doesn’t seems to work.

Any tips? Is this a limit of the text input field or am I doing something wrong?

That’s a question i had on friday as well… it seems like if you use the program always rounds up to 0.001er so even if you use step=“0.01” he shows numbers like 0.156 to me…
I’ve tested it now for a while and always got at maximum 3 digits behind the dot…
Seems like you need to input the value in mili and then reconvert in the program itself…
(eg. entering Volts instead of 0,0001V in 0,1mV and then in programm “int voltage = input * 1000” or something)