Re: calling function in dll not working
A lib file would be easier, but in my case i really need a dll.
When i used dumpbin on my dll it gave me the following output:
dumpbin \EXPORTS path\to\file.dll
File Type: DLL
Summary
1000 .data
1000 .idata
2000 .rdata
1000 .reloc
1000 .rsrc
4000 .text
10000 .textbss
Re: calling function in dll not working
Got it fixed. I had to use declspec(export). This is how it looks right now:
Code:
extern "C" __declspec(dllexport) int testfunc ( int x );
..
..
int testfunc (int x)
{
MessageBoxW ( NULL, L"test", L"blaat", MB_OK );
return x;
}
Thanks alot guys for your help!
Re: calling function in dll not working
Quote:
A lib file would be easier, but in my case i really need a dll.
You know, when you build a dll with export, the lib file is created as well. The one is called DLL's import library. Just search around for simple dll samples. :)