Windows Service started and then stopped using Topshelf
问题 I am using Quartz.net and I am trying to get the Quartz server to start-off in a Windows Service. I have created a Windows Service Project and included the Quartz.net libraries. In my Service class I have: protected override void OnStart(string[] args) { try { Host host = HostFactory.New(x => { x.Service<IQuartzServer>(s => { s.SetServiceName("quartz.server"); s.ConstructUsing(builder => { QuartzServer server = new QuartzServer(); server.Initialize(); return server; }); s.WhenStarted(server =