View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Mike H. Mike H. is offline
external usenet poster
 
Posts: 471
Default Rounding Problem

I have a variable, dimensioned as Single, that I have in a loop doing this:
JETotal=Debit-Credit
Debit and Credit are both also Dim'd as Single.
The Code to accumulate cost is:
JETotal = Round(JETotal + Debit - Credit, 2)
But when done, the JETotal variable does NOT equal Zero. But if I go in the
spreadsheet and sum the 2 columns and net them, I get Zero. How do I solve
this problem?