Click to See Complete Forum and Search --> : Accessing VC++ Compiled Dll in dot net


NRamesh
May 18th, 2002, 12:34 AM
Any idea of referencing/consuming VC++ compiled dll
in dot net [eg:CSharp]

Scenario:
A dll that is developed in VC++ 6.0 is there.
It has to be used in the dot net environment.
A VB compiled dll is easily referenced in the Visual Studio.net
It easily creates a wrapper component for the usage of that dll.
But when tried to add the dll that is compiled in VC++, it gives error
stating "Could not create wrapper assembly for ActiveX type Library. You may need to register it."
But it has been registered.

Arild Fines
May 18th, 2002, 06:11 AM
Is it a COM DLL or a DLL with C-style exports?

NRamesh
May 18th, 2002, 06:15 AM
It is a COM DLL

jparsons
May 18th, 2002, 09:34 AM
Originally posted by NRamesh
It is a COM DLL

If it is a COM DLL then you may simply use the Runtime.Interop services to use the DLL. Check out this site http://www.aspzone.com/articles/john/dotNETInterop/.
It has a good tutorial on how to Mix the 2.