Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP Structure
Message
From
05/02/1999 06:47:08
 
 
To
05/02/1999 05:12:42
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00184248
Message ID:
00184261
Views:
28
>Hi,
> Is there any way to create a structure in VFP as *typedef* in C to allow pass my structure to C program??

Structures can be created in strings and passed by reference to C-style .DLLs; the difficulty comes in constructing memory references outside of VFP-controlled memory variables, since VFP can move things about in memory between VFP statements, and does not provide a native method to retrieve a static pointer to memory.

There are a couple of solutions here on UT; Paul Tatavu's POINTERS class uses an OCX to handle the memory management task. My own CLSHEAP is a very minimalist memory management class that uses only VFP and a few API calls to allocate and deallocate memory blocks and move VFP strings to and from addresses in memory.
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
Previous
Reply
Map
View

Click here to load this message in the networking platform