Late Binding with COM DLL
I am using DLL By name Interop.AMK_MSO300Lib.dll,In C#.net to get Late Binding
When I run Following code:
Assembly myAsm = Assembly.LoadFro("C:\\webaspdotnet\\visualstudio20 05\\BioMetric\\Bin\\Interop.AMK_MSO300Lib.dll");
Type[] types = myAsm.GetTypes();
in types I found all the class of the Interop.AMK_MSO300Lib.dll
but while creating instances with Following code:
foreach (Type typ in types)
{
object obj = Activator.CreateInstance(typ);
prob
}
I got the Following Error:
Creating an instance of the COM component with CLSID {E33C0B90-B568-4308-9F51-12A4BFEDC466} from the IClassFactory failed due to the following error: 80004005
06fa2d94-aad0-366c-8f08-0561a252b8e3,28e89a9f-e67d-3028-aa1b-e5ebcde6f3c8
And I tried With Following Code:
object myObject = Activator.CreateComInstanceFrom("C:\\webaspdotnet\ \visualstudio2005\\BioMetric\\Bin\\Interop.AMK_MSO 300Lib.dll", "TestObject.TestClassClass").Unwrap();
Even then I use to get same error as below
Following Error:
Creating an instance of the COM component with CLSID {E33C0B90-B568-4308-9F51-12A4BFEDC466} from the IClassFactory failed due to the following error: 80004005
06fa2d94-aad0-366c-8f08-0561a252b8e3,28e89a9f-e67d-3028-aa1b-e5ebcde6f3c8
please help me to get the solution for this problem,
|