ADO calculations returning zero 
Author Message
 ADO calculations returning zero

In an application that we are converting to ADO the following calculation
returns zero:

    dblSQFT * ADOrs!PIECES * Forms![kitmaster]![KITPRICING].Form.QUANT

when it should return a result of 2857.1905.

When the code is changed to read

    dblSQFT * cdbl(ADOrs!PIECES) * Forms![kitmaster]![KITPRICING].Form.QUANT

or

    dblSQFT * ADOrs!PIECES * cdbl(Forms![kitmaster]![KITPRICING].Form.QUANT)

the correct answer is returned.

Can anyone tell me why the cdbl function makes this difference? It was
working fine in the old RDO version. I don't want to go through the entire
application and convert every calculation if there's any other way.

Thanks,
Denny Menter
Programmer Analyst
Business Results



Fri, 13 Dec 2002 03:00:00 GMT  
 ADO calculations returning zero
Another clue:
I've also found that reversing the form field and the ADO field produce the
desired result.

Denny Menter



Fri, 13 Dec 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Oracle Returns Zero (0) USing ADO

2. Calculation Results Should Be Zero and Aren't

3. "Zero" supression in calculation fields

4. Replace Function returns Nothing instead of Zero-length string

5. CreateProcess returning a value of zero

6. Microsoft Outlook Express 5 and Netscape, the AttachmentCount property always returns zero

7. Mid returning Zero Length String - sort of

8. Text field in Excel returns null when led by a zero

9. Jet OleDB: Allow zero Length property returns True

10. -Text field in Excel returns null when led by a zero

11. Text field in Excel returns null when led by a zero

12. GetDC Returns Zero

 

 
Powered by phpBB® Forum Software