Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to pass Array binary data to a DLL procedure from VF
Message
From
27/03/2001 01:05:16
 
 
To
27/03/2001 00:22:21
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00488830
Message ID:
00488839
Views:
10
>How do I define and pass Array binary data to a DLL procedure? I am accessing a API that requires I use a Array "BYTE DATA TYPE" to define a work area for the API to manipulate data. How is this done in VFP?
>
>Here is the funtion:
>
>FUNCTION : compress_ANSI_StringBuildALL()
>
>Parameter: workSpace = Points to a buffer, This is where the API holds the larger structures that it deals with . This releases the API from maintaining thses structures on the stack in order to remain re-entrant.
>
>I sent the API developer a email about the API function as here was his reply.. Mind you the developer is not a VFP programer and I'm not a C++ programer so here I am.
>
>****************************
>You probably declare workarea as a String and it can be a problem.
>When passing binary data to a DLL procedure, pass a variable
>as an array of the Byte data type, instead of a String
>variable. Strings are assumed to contain characters,
>and binary data may not be properly read in external
>procedures if passed as a String variable.
>****************************
>Any Ideas?
>
>
>Thanks,
>
>Gary

A string should work for this. Have you tried it? If so, can you post the code that you are using?
Erik Moore
Clientelligence
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform