using d dll/lib with msvc program

Manu turkeyman at gmail.com
Mon May 14 00:39:20 PDT 2012


On 14 May 2012 09:16, Rainer Schuetze <r.sagitario at gmx.de> wrote:

> Than try to load it:
>> HINSTANCE LoadME;
>> LoadME = LoadLibrary(L"C:\\Users\\**CrashTUA\\Documents\\visual studio
>> 2010\\Projects\\DynamicLib1\\**DynamicLib1\\Release\\**DynamicLib1.dll");
>> func dllprintt;
>> dllprintt = (func)GetProcAddress(LoadME,"**trololo");
>>
>
> The C calling convention prepends an underscore to the function name:
> dllprintt = (func)GetProcAddress(LoadME,"_**trololo");


It seems GetProcAddress pulls that off for you. I thought that too, but it
always workout without adding the _ for me.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20120514/e49c3f7b/attachment-0001.html>


More information about the Digitalmars-d mailing list