Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Strange results in COM DLL
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
00467419
Message ID:
00467496
Views:
20
George,
How is the array populated? From something passed from Powerbuilder or directly from a table?

WAG, but since it doesn't work in PB and it does in VFP, maybe variable datatypes have something to do with it. One suggestion (I'm full of them today) would be to attempt to use your COM component from another IDE that uses strong typing (VC++/VB) and see if you get the same results.

>>>>
>>>>George,
>>>>
>>>>There is a bug in TRANSFORM function.
>>>>According to KB Article Q247494 "You might see that the results of the TRANSFORM() function appear off by approximately .0000000000001. This behavior may occur when COMPATIBLE is OFF."
>>>
>>>I'm aware of the KB article, however, if it were the fault of TRANSFORM(), my implemented solution would not work. Indeed, 145.6 when divided by 0.1 is 1456 as TRANSFORM() reported. Remember that the error occurs when comparing two numerical values, TRANSFORM() was only used to report the actual values, so it doesn't really come into play, except in the solution.
>>
>>And what was the actual value?
>>Maybe it was 1456.0000000000001 or 1455.9999999999999 but TRANSFORM reported it as 1456.
>
>TRANSFORM() may have reported it as 1456, but 145.6 / .1 should have also yielded that result. The problem is that it was a straight Boolean evaluation (ie. llBool = (lnNumber1 = lnNumber2)). Further, it worked fine on when called from within VFP, but, against the same data set did not within PowerBuilder.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform