Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

rounding error - formatcurrency()

Status
Not open for further replies.

Gamera99

Programmer
May 17, 2001
59
JP
Does anyone have a good idea how to handle a problem like this?
I am writing rather long tables of financial data on asps; the financial data elements are stored in my database as "money" data type elements which has 4 numbers to the right of the decimal point.
When I display the data on my page, I am using formatcurrency(data,2). The problem is - i get rounding errors when I total up the numbers at the bottom of the page. I accumulate the totals using the data before the formatcurrency statement is applied.
Thanks if anyone has ideas about this.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top