Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How can I use this DLL?
Message
 
To
17/07/2007 15:25:14
Elyse Pomerantz
Dynamic Data Concepts, Inc.
Brooklyn, New York, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01241170
Message ID:
01241263
Views:
31
>>>>>I have the following information (this is an excerpt) about a DLL that I would like to use in my VFP application, but I can't seem to get it to work. What is the correct way to declare and use it? Ultimately I want the value returned from the GetReading() function.
>>>>>
>>>>>
>>>>>typedef struct hdate_t {
>>>>>	WORD	day;
>>>>>	WORD	month;
>>>>>	WORD	year;
>>>>>} HDATE_T;
>>>>>
>>>>>typedef struct reading_t {
>>>>>	int		reading1;
>>>>>	int		reading2;
>>>>>	int		special;
>>>>>} READING_T;
>>>>>
>>>>>KDATE_API HDATE_T	CivilToHebrew(int day, int month, int year);
>>>>>KDATE_API READING_T	GetReading(HDATE_T hd, int diaspora);
>>>>>
>>>>>Thanks!
>>>>
>>>>
>>>>Try:
>>>>
>>>>DECLARE STRING GetReading IN ..... STRING @hd, INTEGER dspr
>>>>
>>>>
>>>>hd  = REPLICATE(CHR(0),3*16)  && Word has 16 bytes
>>>>lcRes = GetReading(@hd, 0)
>>>>? lcRes
>>>>
>>>>The you should convert lcRes from string to 3 integers.
>>>
>>>But the hd parameter that I am passing to GetReading has to be the result of the CivilToHebrew function. How can I declare/use the CivilToHebrew function?
>>
>>
>>
>>
>>Hmmm,
>>try:
>>
>>DECLARE STRING CivilToHebrew IN ..... INTEGER nDay, integer nMonth, integer nYear
>>DECLARE STRING GetReading IN ..... STRING hd, INTEGER dspr
>>
>>lcRes = GetReading(CivilToHebrew(........), 0)
>>? lcRes
>>
>
>I get "Declare DLL call caused an exception."
>Somehow I need to get the structure returned by the CivilToHebrew function and then pass it to the GetReading function.


Can you send me that DLL?
I can't promise that I would answer you today, because I am going to sleep soon :-)
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform