Login
`
Templates, Tools and Utilities
|
||
Add a comment to an Icetips ArticlePlease add your comments to this article.
Please note that you must provide both a name and a valid email address in order
for us to publish your comment. Comments are moderated and are not visible until they have been approved. Spam is never approved!
Back to article list Search Articles Add Comment Printer friendly Direct link Par2: Using Clarion DLLs in VC++ 1998-10-26 -- Dusty Hester There are a few tricks to get VC++ to call a Clarion DLL. Granted I haven't
done this in C4, but I can't imagine it has changed that much from CW2.003.
1) All clarion functions should be displayed as Pascal
2) When passing *cstrings, the Clarion prototype is long, and the C++
prototype is *cstring. The Clarion long will receive the address of the
string, you can then use memcpy to actually get the string into one of your
variables.
3) C++ expects name mangling...I always used the Name attibute on my
Clarion function to mimic what the C++ compiler is looking for.
4) You have to create your own .lib file. You will do this by creating a
.def file, specs are in the C++ docs, and using the Lib tool to create a
.lib from it.
I hope this is enough to get you started in the right direction. Again, I
haven't done this in almost a year, so some of this may be outdated, but I
doubt it.
Today is November 21, 2024, 6:37 am This article has been viewed 35214 times.
|
|