Using Visual Studio 2015. Created a windows service project. I'm trying to use topshelf, but can't seem to debug.
Output debug / window says:
Topshelf v3.3.154.0, .NET Framework v4.0.30319.42000 Topshelf.Hosts.ConsoleRunHost Error: 0 : An exception occurred, System.IO.IOException: The operation completed successfully.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) at System.IO.__Error.WinIOError() at System.Console.set_Title(String value) at Topshelf.Hosts.ConsoleRunHost.Run()
For those not familiar with Topshelf: http://docs.topshelf-project.com/en/latest/index.html
Topshelf is a Windows service framework for the . NET platform. Topshelf makes it easy to create a Windows service, test the service, debug the service, and ultimately install it into the Windows Service Control Manager (SCM).
Topshelf is a framework for hosting services written using the . NET framework. The creation of services is simplified, allowing developers to create a simple console application that can be installed as a service using Topshelf.
Start Visual Studio with administrative credentials so you can attach to system processes. (Optional) On the Visual Studio menu bar, choose Tools, Options. In the Options dialog box, choose Debugging, Symbols, select the Microsoft Symbol Servers check box, and then choose the OK button.
Appears Topshelf expects the output type be set to "Console Application."
Project Properties/Application/Output Type: Console Application.
I guess I missed the key concept which is to create a console application which enables you to install it as a windows service.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With