Reputation: 22956
I have a C++ DLL compiled natively and I'd like to write a CLR wrapper for it. After building the DLL and placing it in the CLR project directory I added the header file to correspond to it.
When I build I get linker errors about the functions in the DLL not existing.
I've already tried adding the DLL to the 'executable directory'.
How do I link up the external DLL to the CLR C++ project?
Upvotes: 1
Views: 2016
Reputation: 5529
If it's a linker error, you probably forgot to include the .exp or .lib file associated with your DLL in your Additional Dependencies. Usually MSVC will generate a .exp and/or .lib file to help you link to your DLL.
Upvotes: 3