link from a dll to another function in another dll?
maarten van damme
maartenvd1994 at gmail.com
Fri Apr 22 03:22:26 PDT 2011
That example was a bit incomplete, preceding was the following code:
import std.c.windows.windows;
import core.dll_helper;
pragma(lib,"kernel33.lib");
__gshared HINSTANCE g_hInst;
extern (Windows)
BOOL DllMain(HINSTANCE hInstance, ULONG ulReason, LPVOID pvReserved)
{
switch (ulReason)
{
case DLL_PROCESS_ATTACH:
g_hInst = hInstance;
dll_process_attach( hInstance, true );
break;
case DLL_PROCESS_DETACH:
dll_process_detach( hInstance, true );
break;
case DLL_THREAD_ATTACH:
dll_thread_attach( true, true );
break;
case DLL_THREAD_DETACH:
dll_thread_detach( true, true );
break;
}
return true;
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20110422/59f46e87/attachment-0001.html>
More information about the Digitalmars-d
mailing list