I am loading an extension dll from my mfc client application, when click on the menu first time the dll dialog is being loade and after i exit or close the dialog, and again clicking on the menu to load again it's giving error that "A required resource was unavailable". what could be the problem please help me to resolve this
void CTestRevApp ::On3DView()
{
typedef VOID (*MYPROC)(CString);
MYPROC ProcAdd;
BOOL fRunTimeLinkSuccess = FALSE;
hinstLib = LoadLibrary(L"C:\\Documents and Settings\\sdh\\My Documents\\REVOLUTIONPROJ_DB\\DllDialog\\package\\DllTest\\Release\\dlltest.dll");
if( hinstLib == NULL)
FreeLibrary(hinstLib);
ProcAdd = (MYPROC)GetProcAddress(hinstLib, "runAppli");
ProcAdd(NULL);
if(ProcAdd == NULL)
{
AfxMessageBox(L"Unable to get pointer to function runAppi()");
FreeLibrary(hinstLib);
hinstLib = NULL;
return;
}
return;
}