Thanks for the suggestion. I saw that link before but dismissed it for some
reason. I guess I assumed it was doing something else. In any event, I just
tried it and it DID come up with different output but still not what it
should be. I may very well be using it wrong though. It's probably obvious
that I'm no Java programmer. I'm basically just taking what I know about
programming in general and the syntax of JavaScript and doing the best I can
here.

This is what I have from your suggestion and what it displays.

import java.text.*;
import java.math.BigDecimal;

public class dollarFormattingTest
{
public static void main(String[] args)
{
DecimalFormat dollarFormat = new DecimalFormat("$0.00");
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.815)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.825)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.835)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.845)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.855)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.865)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.875)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.885)));
System.out.println(dollarFormat.format(new java.math.BigDecimal(71.895)));
}
}


This is the output now...

$71.81
$71.83
$71.83
$71.84
$71.86
$71.86
$71.88
$71.89
$71.89

That's either extremely weird... or I'm completely missing something
obvious. :-/


-----Original Message-----
From: Denny Valliant [mailto:[EMAIL PROTECTED] 
Sent: Saturday, October 07, 2006 1:25 AM
To: CF-Talk
Subject: Re: Java help

Could this be it?

http://forum.java.sun.com/thread.jspa?threadID=736383&messageID=4230346


On 10/6/06, Bobby Hartsfield <[EMAIL PROTECTED]> wrote:
> I should also mention that I tried this as well...
.....

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.407 / Virus Database: 268.13.0/465 - Release Date: 10/6/2006
 



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered to your door four 
times a year.
http://www.fusionauthority.com/quarterly

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:255882
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to