Use the LoadLibraryEx32W function in 16-bit code to load a 32-bit DLL.
DWORD FAR PASCAL LoadLibraryEx32W(
LPCSTR lpszLibFile, // points to name of executable module
DWORD hFile, // reserved, must be NULL
DWORD dwFlags // entry-point execution flag
);
DONT_RESOLVE_DLL_REFERENCES
LOAD_LIBRARY_AS_DATAFILE
LOAD_WITH_ALTERED_SEARCH_PATH
If the function succeeds, the return value is a 32-bit handle to a DLL module. If the function fails, the return value is NULL.
After calling this function, the 16-bit thunk DLL can call the GetProcAddress32W function to get the address of the 32-bit entrypoint function(s) and then call the thunk(s) by using the CallProc32W or CallProcEx32W function.
Windows 95 and Windows 98: This function releases the Win16Mutex. If this function is called from a 16-bit DLL, it can be reentered as soon as the 32-bit DLL entry-point function is called. This happens when another 32-bit process thunks to the 16-bit DLL or when another 16-bit DLL calls this 16-bit DLL. However, if this function is called in a 16-bit application and the 32-bit DLL entry-point function does not yield, the function is not reentered.
CallProc32W, CallProcEx32W, GetProcAddress32W