Service runs then dies

后端 未结 2 1937
无人共我
无人共我 2021-01-23 17:37

I\'m running Win 7 Pro 64-bit. I wrote a service in C# using the .NET 4 framework. It installs properly and starts to run. I know that it runs because it writes some output t

2条回答
  •  没有蜡笔的小新
    2021-01-23 17:50

    Use System.Diagnostics.Debugger.Launch to run it as a service and debug. If it doesn't crash in that scenario add additional logging and make sure to add a top level catch to write out any error. If that still doesn't do it create a crashdump file and examine with with SOS and windbg.

提交回复
热议问题