Article ID: 173247
Article Last Modified on 8/17/2005
1.15
0.075
8.885
X = Format(0.075, "$#.##")
use this:
X = Format(Application.Round(0.075, 2), "$#.##")
The Round method accepts two arguments; the value to be rounded (in
this case, 0.075), and the number of decimal places to which you want
the value to be rounded (in this case, 2).
X = Format(0.075, "$#.###")
Since the value and the format expression both use three decimal
places, the problem will not occur.MsgBox Format(0.075, "$#.##")In Microsoft Excel 5.x, the message box displays the value $.08. In Microsoft Excel 7.x and Microsoft Excel 97, the message box displays the value $.07.
Additional query words: XL97 XL7 XL5 IEEE XL
Keywords: kbprb KB173247