Round to 2 decimals
783898Oct 22 2010 — edited Oct 26 2010I want to round to 2 decimal places the number that i put in th text field.
For Eg:
IfI put 17.876 I want it as 17.87.
I am trying to call js in change even of this text field but it is giving me 17.00.I am using toFixed(2) function in this.
GIven below is the copy of my js function.
$x('P3_CHARGES').value = ($x('P3_CHARGES').value).toFixed(2);