Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VB Call to API vs VFP
Message
De
21/08/1999 10:34:49
 
 
À
21/08/1999 01:41:10
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Divers
Thread ID:
00255827
Message ID:
00256248
Vues:
26
>>>And SINGLE and DOUBLE don't work properly for the return value.
>>>
>>
>>Actually, from a bit of experimentation with Christof's help, we proved out that SINGLE and DOUBLE put the value back into the variable, but it doesn't update the value with the new precision, resulting in some funny rounding. As I pointed out, pre-initing a DOUBLE variable to a value with correct precision seems to work OK (IOW, init the variable receiving the DOUBLE or SINGLE to 0.00000000000000000000) and it seems to work OK; it definitely fixed the problem with DOUBLE passed by reference and copied in and out using RtlMoveMemory() in a parameter.
>
>I was talking about return value, not parameters. Did you find a solution for return values too?
>

I honestly haven't tried, at least in part because I don't have a call that returns a SINGLE or DOUBLE; I suspect that it won't work easily, since I think that VFP's API interface always creates a complete new value entry for the return rather than inheriting the number of decimal places in the numeric when a pass by reference occurs, but I haven't tried it out. I'll try to kludge something up this weekend to test it.
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform