Thread
:
Round to 2 decimal places
View Single Post
#
2
(
permalink
)
07-02-2009, 02:32 AM
Dragunov
Junior Member
Join Date: Jun 2009
Posts: 14
did you try like this
Math.round(val*Math.pow(10,dec))/Math.pow(10,dec)
where "dec" is the for precision ie. the number of decimal places you want and "val" is the original decimal value .
Dragunov
View Public Profile
Find all posts by Dragunov