What about the way Microsoft is suggesting to bind COM-objects to managed
code?
They suggest to add a reference to the COM-class to the reference list of
the project, wich will
generate a managed assembly wrapping the COM-class. Then they'll bind it the
folowing way:
...
using NameOfImportedCOMLib; //Just the wrapper-assemblies namespace
...
{
NameOfImportedCOMLibClass myInstance = new NameOfImportedCOMLibClass
();//Creating an object from wrapper class as with any other class
myInstance.DoSumptin ();//Use as any other object
...
}
...
Stefan
im Newsbeitrag news:
[email protected]...
Hello Stefan,
Take a look at the System.Activator.CreateInstance(...) and
System.Type.GetTypeFromProgID(...)
Not sure there's an equivalent. I hope somebody else will shed more
light
on
this.
--
Dmitriy Lapshin [C# / .NET MVP]
X-Unity Test Studio
http://x-unity.miik.com.ua/teststudio.aspx
Bring the power of unit testing to VS .NET IDE
Stefan Saur said:
Hello,
I have the commands to access the AutoCAD database via
ActiveX within a VB application. Now I am searching for
the equivalent commands in C#:
VB --> C#
GetObject --> ???
CreateObject --> ???
Can you help me?
Thx
Stefan