C
Cengiz
Hi,
i've created DLL with VC++ 6.0 with the following code.
--------------------------------------------------
int __declspec(dllexport) initialize(void)
{
MessageBox(0,"TEST","TEST",0);
return 0;
}
--------------------------------------------------
In another project i call this method.
--------------------------------------------------
typedef int (*INITIALIZE) ( void );
INITIALIZE initialize;
HINSTANCE hDLL = NULL;
if( hDLL == NULL )
{
hDLL = LoadLibrary( "Test2" );
if (hDLL == NULL)
{
MessageBox(0, "Test2.dll not found!", "", 0 );
return FALSE;
}
if(!(initialize = (INITIALIZE)GetProcAddress(hDLL, "initialize")))
MessageBox(0, "ERROR", "initialize", 0 );
else initialize();
FreeLibrary( hDLL );
hDLL = NULL;
}
i've created DLL with VC++ 6.0 with the following code.
--------------------------------------------------
int __declspec(dllexport) initialize(void)
{
MessageBox(0,"TEST","TEST",0);
return 0;
}
--------------------------------------------------
In another project i call this method.
--------------------------------------------------
typedef int (*INITIALIZE) ( void );
INITIALIZE initialize;
HINSTANCE hDLL = NULL;
if( hDLL == NULL )
{
hDLL = LoadLibrary( "Test2" );
if (hDLL == NULL)
{
MessageBox(0, "Test2.dll not found!", "", 0 );
return FALSE;
}
if(!(initialize = (INITIALIZE)GetProcAddress(hDLL, "initialize")))
MessageBox(0, "ERROR", "initialize", 0 );
else initialize();
FreeLibrary( hDLL );
hDLL = NULL;
}