FTIISD
asked on
Subtraction using double
Hi,
Im am running the following code:
frmAddToFile.txtBalance = Val(frmAddToFile.adoFileIn formation. Recordset. Fields("sa leamount") ) - Val(frmAddToFile.txtTotalP aidToDate) - Val(txtAmountPaying.Text)
where frmAddToFile.adoFileInform ation.Reco rdset.Fiel ds("saleam ount") = 10707.49
and frmAddToFile.txtTotalPaidT oDate = 8022.89
and txtAmountPaying.Text = 2684.60
this should compute to 0 but instead it = -4.54747350.......
I understand this has to do with the way it is stored in binary, but I need a way of making this work.
Thanks!
Im am running the following code:
frmAddToFile.txtBalance = Val(frmAddToFile.adoFileIn
where frmAddToFile.adoFileInform
and frmAddToFile.txtTotalPaidT
and txtAmountPaying.Text = 2684.60
this should compute to 0 but instead it = -4.54747350.......
I understand this has to do with the way it is stored in binary, but I need a way of making this work.
Thanks!
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks for the help!