DLL Troubles (OpenInsight Specific)
At 29 DEC 1999 04:45:44PM Eric H. Hilder wrote:
Hello all!
I am trying to use a third party DLL for Communications.
The documentation lists one the routines using the following function protocol:
hPORT COMMWinInit(WORD, long, short, short, short, WORD, WORD)
I have created a DLL Function Protocol in the SYSPROCS file using the following definition:
MCW32.DLL
LPVOID PASCAL COMMWinInit(DOUBLE, LONG, SHORT, SHORT, SHORT, DOUBLE, DOUBLE)
I then ran Declare_FCNS and created the neccessary SYSOBJ items.
However, when I run the routine, I get the following error message:
Function COMMWININIT does not exist in dynamic link library MCW32.DLL
Where do I go from here? Did I properly convert the parameter types? If the parameter type are not correctly defined, would the above error message be received?
Any help is appreciated. I can forward over a copy of the DLL if anyone wants to run any tests.
Thanks in Advance,
Eric H. Hilder
At 29 DEC 1999 06:32PM Oystein Reigem wrote:
Eric
DOUBLE is 8 bytes. Try LONG instead for WORD. But my bet is there's something different causing the error message.
- Oystein -
At 30 DEC 1999 10:20AM Matt Sorrell wrote:
Eric,
Just a thought here, but based on the name of the DLL it appears to be a 32-bit DLL and OI is a 16-bit app. You can thunk the DLLs but that usually requires writing your own DLL in C that you call instead, it turns around and calls the 32-bit DLL, and then returns the results back to you.
I may be way off base here, but that's all I can think of.
Matt Sorrell
msorrel@greyhound.com
At 30 DEC 1999 01:22PM Eric H. Hilder wrote:
You may be onto to something here. I will have to call the company. They were supposed to supply a 16-bit DLL as well, but they only sent me the 32-bit DLL.
Thanks for the insight.
Eric H. Hilder