I have developed a windows service, I can debug it using visual studio and it works as expected. But if I install the service using the installUtil.exe
and start it I'm getting the following exception:
System.Runtime.InteropServices.SEHException (0x80004005): External component has thrown an exception.
I tried cleaning the solution, uninstalled and re-installed it. I even restarted my computer but nothing changes. I tried running the windows service with my local administrator credentials but the result is the same. I can install and start the service successfully on my coworkers computer. What do you suggest to me to start the service successfully on my own computer?
I had a similar problem, where a C# service application installed on one particular computer failed to start, with the same error as above logged in the Windows Event Log.
Deleting the application's installed executable file and copying it manually from the installer image solved the problem. Hence it appears that a corrupt file can lead to that type of SEHException.
User contributions licensed under CC BY-SA 3.0