cdbl - Posted (1129 Views)
Starting Member
Fromafarr
Posts: 7
7
Hi, When my script adds 100.01 and 100.20 together it produces 200.21 but if it adds 100.00 and 100.00 it produces 200 .I need it to produce 200.00. I am sure i am missing something. I am using cdbl to format my vaiable. Thanks in advance.<
 Sort direction, for dates DESC means newest first  
 Page size 
Posted
Advanced Member
Carefree
Posts: 4224
4224
Use the command "FormatNumber(<your variable>,2)"<
Posted
Starting Member
Fromafarr
Posts: 7
7
Thanks for that. I now have to add together my variables i.e FormatNumber(total1,2)+FormatNumber(total2,2) but get to many .00 returned.<
Posted
Forum Moderator
AnonJr
Posts: 5768
5768
I think he was telling you to use FormatNumber on the result, not on each number as you add it.<
 
You Must enter a message