https://bugs.documentfoundation.org/show_bug.cgi?id=157856

--- Comment #4 from [email protected] ---
Yes, sorry, I meant LibreOffice Calc is giving the error and OpenOffice Calc
does not have this issue.

The macro simply adds the first two cells (30 and 31 below) together via
variable 'balance' to confirm that the sum equals the value of the third cell
(35 below).
I've used it for years on OpenOffice Calc no problem and just started using
LibreOffice Calc this week and it gave this error.

The BASIC macro If statement correctly returns true in OpenOffice Calc but
incorrectly returns false in LibreOffice Calc.
Here is the code of concern:

Dim balance
balance = 0
Cell3 = LogSheet.getCellByPosition(30, Sub2Counter) 'The 0.05 value cell.
balance = balance + Cell3.Value 
Cell3 = LogSheet.getCellByPosition(31, Sub2Counter) 'The 0.90 value cell.
balance = balance + Cell3.Value
Cell3 = LogSheet.getCellByPosition(35, Sub2Counter) 'The 0.95 value cell.
If balance = Cell3.Value Then                       ' This is returning a wrong
false in LibreOffice Calc.
Else  ' report an error if the tally doesn't match what's on the Log sheet

It worked fine with other decimal-place values. Not sure why these played up.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to