------------
~Chris Baker
Sophomore Computer Science Student
Co-VP of MUFencing
Miami University (OH)
java.text.NumberFormat.getCurrencyInstance().format(45.63563564)); // locale
specific
or
new java.text.DecimalFormat("$0.00").format(45.63563564));
--
Mike W
>I know that there is an easy way to convert a double to a currency string,
>but i can't seem to figure it out. I'm looking to convert a double like
>4.5233 to a dollar amount like $4.52. any help is appreciated, and thanks in
>advance!
see http://mindprod.com/jgloss/currency.html
see http://mindprod.com/converter.html
see http://mindprod.com/jgloss/floatingpoint.html
--
Canadian Mind Products, Roedy Green.
Coaching, problem solving, economical contract programming.
See http://mindprod.com/jgloss/jgloss.html for The Java Glossary.