Windows 2008 64 bit OS Retrieving the COM class factory failed - asp.net

I am doing excel automation at Server Side through my website .The code uses excel interop dlls. The server I am deploying is 64 bit windows 2008 . I tried most of the options I researched in web but still getting below message.
Options tried :
1) Configured IIS 7 Aplication pool to accept 32 bit app -failed
2) Rebuild the code with Target platform as X86 - failed
3) Created desktop folders under C:\Windows\SysWOW64\config\systemprofile\Desktop - failed
Retrieving the COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)).
Exception Details: System.Runtime.InteropServices.COMException: Retrieving the COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)).

Related

System.Runtime.InteropServices.COMException: Retrieving the COM class factory for component with CLSID {840177AB-C69A-463C-8FAF-8137489EF565}

System.Runtime.InteropServices.COMException: Retrieving the COM class factory for component with CLSID {840177AB-C69A-463C-8FAF-8137489EF565} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)).
I am getting this error while running code on Windows 10, the same code is working fine on my Windows 7 system.

System.Runtime.InteropServices.COMException: 'The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))'

I am working with zkemkeeper 64 bit. I am having an error When i ccall
bool a = axCZKEM1.Connect_Net(IPAddress, Port);
axCZKEM1 is my zkemkeeper.CZKEMClass object.
The following error i am getting.
System.Runtime.InteropServices.COMException: 'The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))'
Can you please help me with this ?
It is because COM dll files are not registered. you must have something like install.bat, run it in admin mode. Or find the Dll files from the download SDK folder, register all of them, then run the application. Problem will be resolved.

MSDeploy build after win upgrade

I am doing a msdeploy in the Developer Command Prompt (Admin) and after updating to Win 8.1 Pro, I get this error after running the command.
I did not get this error before the update I got another error USER NOT ADMIN to fix this I had to upgrade so I could create a group and add deploy as Admin.
Please forgive any bad formatting first timer.
>..\..\lib\msdeploy\msdeploy -verb:sync -source:package='Package.zip' -dest:contentPath='test.dev',computerName=localhost,userName=deploy,password=xxxx
Error: Exception has been thrown by the target of an invocation. ---> System.Exception: The type initializer for 'Microsoft.Web.Deployment.DeploymentManager' threw an exception. ---> System.Exception: The type initializer for 'Microsoft.Web.Deployment.BuiltInTypesCache' threw an exception. ---> System.Exception: The type initializer for 'Microsoft.Data.Tools.Schema.MsDeploy.MsDeployProviderBaseProviderFactory' threw an exception. ---> System.IO.IOException: Could not load file or assembly 'file:///C:\Program Files (x86)\Microsoft SQL Server\110\DAC\Bin\Microsoft.Data.Tools.Schema.Sql.dll' or one of its dependencies. Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED)) ---> System.Exception:Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED))
I believe this part of the error indicates you need to install, repair or uninstall/reinstall the 2012 version of the SQL Server Data Tools:
System.IO.IOException: Could not load file or assembly 'file:///C:\Program Files (x86)\Microsoft SQL Server\110\DAC\Bin\Microsoft.Data.Tools.Schema.Sql.dll' or one of its dependencies.

Log4j2 with Websphere Application Server org.apache.logging.log4j.web.Log4jServletContainerInitializer not a subtype

We have an application which uses Log4j2 and running on WAS 8.5. We have selected the class loading option as PARENT_LAST, so the jar files will be picked up from WEB-INF/lib. We are error getting the below error when starting up the server.
com.ibm.ws.exception.RuntimeWarning: com.ibm.ws.webcontainer.exception.WebAppNotLoadedException: Failed to load webapp: Failed to load webapp: javax.servlet.ServletContainerInitializer: Provider org.apache.logging.log4j.web.Log4jServletContainerInitializer not a subtype
at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:432)
at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:718)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1177)
at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1370)
at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:639)
at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:968)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:776)
at com.ibm.ws.runtime.component.ApplicationMgrImpl$5.run(ApplicationMgrImpl.java:2195)
at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5387)
at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5603)
at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2200)
at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:435)
at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123)
at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:378)
at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:126)
at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$CUInitializer.run(CompositionUnitMgrImpl.java:984)
at com.ibm.wsspi.runtime.component.WsComponentImpl$_AsynchInitializer.run(WsComponentImpl.java:502)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1865)
Caused by: com.ibm.ws.webcontainer.exception.WebAppNotLoadedException: Failed to load webapp: Failed to load webapp: javax.servlet.ServletContainerInitializer: Provider org.apache.logging.log4j.web.Log4jServletContainerInitializer not a subtype
at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:759)
at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:634)
at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:426)
... 18 more
Caused by: com.ibm.ws.webcontainer.exception.WebAppNotLoadedException: Failed to load webapp: javax.servlet.ServletContainerInitializer: Provider org.apache.logging.log4j.web.Log4jServletContainerInitializer not a subtype
at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:176)
at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:749)
... 20 more
Caused by: java.util.ServiceConfigurationError: javax.servlet.ServletContainerInitializer: Provider org.apache.logging.log4j.web.Log4jServletContainerInitializer not a subtype
at java.util.ServiceLoader.fail(ServiceLoader.java:243)
at java.util.ServiceLoader.access$300(ServiceLoader.java:193)
at java.util.ServiceLoader$LazyIterator.next(ServiceLoader.java:381)
at java.util.ServiceLoader$1.next(ServiceLoader.java:457)
at com.ibm.ws.webcontainer.webapp.WebAppImpl.initializeServletContainerInitializers(WebAppImpl.java:535)
at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:409)
at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88)
at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169)
When we have the lo4j2 related jar's as part of the ext folder of the server, it is working fine without any issues.
We also have log4j jar's as well as part of the application which is being used by some third party jar's.
Can some throw some light as what is going on here and why this error is being thrown?
If you are using web.xml for your application configuration refer to following link for configuring log4j-web module related listener and filter.
http://logging.apache.org/log4j/2.x/manual/webapp.html

Remote execution of Coded UI Tests on a Windows XP VM

I have a Coded UI + SpecFlow test project (.NET Framework 4).
I want to perform remote test execution, so I configured a Visual Test Agent - Controller environment setup. My local machine is the Controller and there is a virtual machine which is the agent. The AUT will run on a Windows Embedded System with Windows XP SP3. The AUT is a WPF application.
VM properties:
Windows XP SP 3
Microsoft Test Agent 2012 is installed on the VM (Agents for Visual Studio 2012 Update 3)
The agent-controller communication is established successfully (Agent - Online, OK; Controller - Running, OK; TestSettings.testsettings - Configured, OK). The test execution is performed using mstest.
The following error is displayed when I execute the tests:
Test Name: CodedUITestMethod1
Test FullName: Remote.Test.CodedUITest1.CodedUITestMethod1
Test Source: c:\Users\user\Documents\Visual Studio 2012\Projects\Remote.Test\Remote.Test\CodedUITest1.cs : line 27
Test Outcome: Failed
Test Duration: 0:00:01.7131241
Result Message: Error calling Initialization method for test class Remote.Test.CodedUITest1: System.IO.FileLoadException: Could not load file or assembly 'Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowser, Version=11.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. Strong name validation failed. (Exception from HRESULT: 0x8013141A) ---> System.Security.SecurityException: Strong name validation failed. (Exception from HRESULT: 0x8013141A)
Result StackTrace:
--- End of inner exception stack trace ---
at System.Reflection.RuntimeAssembly.nLoadFile(String path, Evidence evidence)
at System.Reflection.Assembly.LoadFile(String path)
at Microsoft.VisualStudio.TestTools.UITest.Framework.UITestExtensionPackageManager.LoadAssembly(String assemblyFile)
By definition Coded UI does not support Windows XP.
Is there a workaround for the upper mentioned issue? Any suggestions?
Thank you,
Isolation of Microsoft.VisualStudio.TestTools.UITest.Extension.CrossBrowser.dll from c:\Program Files\Common Files\microsoft shared\VSTT\11.0\UITestExtensionPackages\ solved the problem. Action was performed on the remote VM.
The tests are up and running.

Resources