The first line should read:

I have the NumberFormat() func formatting a number with zeros.  The
result is one integer higher than the original integer.

Thanks,
-Vinny DiDonato
AOL Handle = Vinny49


-----Original Message-----
From: Vinny DiDonato [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, December 05, 2001 11:37 AM
To: CF-Talk
Subject: NumberFormat() Rounding Up


Hello:

I have the NumberFormat() func rounding up a number.  The result is one
integer higher than the original integer.

Example:
NUMBERFORMAT(5111111111111111, '00000000000000000000')

This yields 00005111111111111112 on CF 4.5.
It's supposed to print 00005111111111111111.

However, if the first number in the string is <= 5, the last number is
always +1 (so the code above would yield 2).  
If the first number in the string is >=4, the last number is always
correct (or 1 in the string above.).  If the first number = 9, the last
number is always -1 (so the code above would yield 0).

This happens on CF 4.5.  CF 5.0 does not have this issue, but our
commerce system is on 4.5.

Any help or logical explanation would be great, because this doesn't
make sense to me.

-Vinny DiDonato
AOL Handle = Vinny49 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to