SyntaxFix
Write A Post
Hire A Developer
Questions
I would suggest using String.format() if you need the value as a String in your code.
String
For example, you can use String.format() in the following way:
String.format()
float myFloat = 2.001f; String formattedString = String.format("%.02f", myFloat);