Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
FindWindow
Message
From
04/01/1999 20:30:43
 
 
To
04/01/1999 10:44:41
Calvin Smith
Wayne Reaves Computer Systems
Macon, Georgia, United States
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Title:
Miscellaneous
Thread ID:
00172288
Message ID:
00172616
Views:
34
The others already explained almost everything. :)

Delphi's pChar is a pointer to char, which is exactly C's pointer to char (char* or LPSTR). LPCTSTR is a constant pointer to char (or wide char if on Unicode). VFP doesn't have pointers, so, it doesn't have a direct equivalent.

A pointer is in fact a 32-bit unsigned integer, so wherever you see a LP... (or P...) you can use INTEGER in DECLARE command. The STRING declaration for a string parameter passes in fact a pointer. This is why VFP accepts an integer where a string is expected. But this is useful only (almost) if yoy need to pass a null pointer.

In this particular case, you can declare the first param as INTEGER if you want to be "consistent" with its use.

Vlad

>Thanks, it works. However, is there some book,document or whatever that explains all this. I mean, it looks like you are declaring a function that is going to receive 2 string parameters and then it is called with 1 numeric and 1 string. This is not intuitively obvious. In Delphi, I call the same function with 2 pChar parameters. I didn't think C was this forgiving. Again, Thanks :)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform