|
-
Mar 8th, 2008, 07:33 PM
#6
Re: [3.0/LINQ] DLLImport from a C++ DLL
Unmanaged non-COM libraries cannot be registered.
.NET assemblies can't be registered unless they expose a COM interface. If the assembly is not loaded into the GAC, you could use gacutil to manually import it.
Unmanaged DLLs are searched for in the directories specified in the PATH environment variable. If you have it in another, you must fully qualify the path in the DllImport attribute.
You should also mark your C++ functions as stdcall. I think the default is cdecl, even for exported functions.
Last edited by penagate; Mar 8th, 2008 at 07:39 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|