PRB: DLL Fails to Initialize If User-Defined Entry Point Is Used (314657)
The information in this article applies to:
- Microsoft Visual C++ .NET (2002)
This article was previously published under Q314657 SYMPTOMS
When you use the /clr and /entry options to build a dynamic link library (DLL), the DLL may not be initialized properly. As a result, the application may not start.
CAUSE
This happens if the user-defined entry point function has an incorrect signature.
RESOLUTION
If you are using the /entry switch along with /clr to compile your DLL, use the following entry point parameters:
BOOL WINAPI <your_entrypoint_name>(LPVOID hinstDLL,
DWORD dwReason,
LPVOID lpvReserved)
-or-
BOOL WINAPI <your_entrypoint_name>(void* hinstDLL,
DWORD dwReason,
void* lpvReserved)
REFERENCES
For other top-hit Visual C++ .NET Microsoft Knowledge Base articles, visit the following Microsoft Web site:
For more information about the Visual C++ Compiler options, visit the following Microsoft Web sites:
Modification Type: | Major | Last Reviewed: | 7/23/2002 |
---|
Keywords: | kbCompiler kbCRT kbDSupport kbIJW kbManaged kbprb kbProd2Web KB314657 |
---|
|