Limit function to 2 decimal places
-
Hi @codepeople,
I am trying to limit these functions to 2 decimal places.
I have used the PREC(),2) in various ways but can’t seem to get it right.Below is the function I would like to limit to 2 decimal places:
(function(){ if(fieldname1 == 100) return 0.20*fieldname2; if(fieldname1 == 200) return 0.39*fieldname2; if(fieldname1 == 300) return 0.60*fieldname2; if(fieldname1 == 400) return 0.78*fieldname2; if(fieldname1 == 500) return 0.98*fieldname2; })()
I would really appreciate your help once again.
ThanksThe page I need help with: [log in to see the link]
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Limit function to 2 decimal places’ is closed to new replies.