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 Clarion in general: Loading clarion DLL and execute a procedure 2002-12-16 -- Andy Ireland Newsgroups: softvelocity.products.c55ee
You do not need to use C, here's a clarion example binding it to a class.
This way you can encapsulate bound calls like this for specific
functionality into a class that wraps the whole shooting match so you do not
have code here there and everywhere but instead all in one place where it
should be, a class and it's module.
map
ProcToCallStub(long pwszVersion, |
long pwszBuildFlavor, |
long flags, |
REFCLSID rclsid, |
REFIID riid, |
*long pvObject),HRESULT,pascal,type
module('')
ProcToCall(ObjFactory Of, |
long pProcToCall, |
long pwszVersion, |
long pwszBuildFlavor, |
long flags, |
REFCLSID rclsid, |
REFIID riid, |
*long pvObject),HRESULT,name('_ProcToCall')
end
end
ObjFactory class........
ProcToCall procedure(ProcToCallStub pProcToCall, |
long pwszVersion, |
long pwszBuildFlavor, |
long flags, |
REFCLSID rclsid, |
REFIID riid, |
*long pvObject),|
HRESULT,name('_ProcToCall'),private
end
Then calling the method will allow binding to the call as follows....
ObjFactory.ProcToCall procedure(ProcToCallStub pProcToCall, |
long pwszVersion, |
long pwszBuildFlavor, |
long flags, |
REFCLSID rclsid, |
REFIID riid, |
*long pvObject)
code
pvObject = 0
return pProcToCall(pwszVersion, pwszBuildFlavor, flags, rclsid, riid, pvObject)
then just call as a normal method.
HTH
Regards
Andy
Plugware Solutions.com Ltd, taking the puzzle out of I.T
Tel : +44 1249 813335
Fax : +44 1249 813462
Today is December 3, 2024, 11:58 am This article has been viewed 35228 times. Google search has resulted in 62 hits on this article since January 25, 2004.
|
|