COMException when creating COM object for Excel Automation in C# -


i've got error when create com object in order use excel automation. 1 knows why getting error?

system.runtime.interopservices.comexception(errorcode = -2146959355) message: retrieving com class factory component clsid {00024500-0000-0000-c000-000000000046} failed due following error: 80080005.

the call stack following:

system.runtime.remoting.remotingservices.allocateuninitializedobject(runtimetype objecttype) @ system.runtime.remoting.remotingservices.allocateuninitializedobject(type objecttype) @ system.runtime.remoting.activation.activationservices.createinstance(type servertype) @ system.runtime.remoting.activation.activationservices.iscurrentcontextok(type servertype, object[] props, boolean bnewobj) @ system.runtimetypehandle.createinstance(runtimetype type, boolean publiconly, boolean nocheck, boolean& canbecached, runtimemethodhandle& ctor, boolean& bneedsecuritycheck) @ system.runtimetype.createinstanceslow(boolean publiconly, boolean fillcache) @ system.runtimetype.createinstanceimpl(boolean publiconly, boolean skipvisibilitychecks, boolean fillcache) @ system.activator.createinstance(type type, boolean nonpublic) @ geotab.comobject..ctor(type type)

this code: type excelapptype = type.gettypefromprogid("excel.application"); comexcelobject = new comobject(excelapptype);

the error code (0x80080005) co_e_server_exec_failure, "server execution failed". in other words, went wrong when com tried start excel.exe. pretty basic problem has way many possible causes. check windows event log possible better diagnostic. usual next step reinstalling office.


Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -