This is the function prototype for LoadLibrary:
HMODULE WINAPI LoadLibrary(
LPCTSTR lpFileName
);
Your call assigns to an HINSTANCE and not an HMODULE.
The arguiment is an LPTCTSR (a long pointer to a const TCHAR string). You have provided:
HINSTANCE hInstLibrary = LoadLibrary(L"C:\\newproject80\\output\\cpp\\FFB20 00\\FFB.dll");
which is a wchar_t string. Not good.
Your code should be:
-
HMODULE hInstLibrary = LoadLibrary(TEXT("C:\\newproject80\\output\\cpp\\FFB2000\\FFB.dll"));
-
LoadLibrary is a macro that resolves to LoadLibraryA or LoadLibraryW based on the character set (char or wchar_t) used on the build. The TEXT is a TCHAR macro that provides a char string when the build character is char and provodes a wide string when the build character set is multi-byte.
Try this and let me know what happened.
BTW: I hope you are using an _tmain() and all those _t functions.