getting error while try to start service
views:
601answers:
2answer: if you are getting this error check the service name and service process installer service name. Both must be the same.
happy coding
Also ensure that in the entry point for the exe (usually the Main procedure) an instance of the your service class (that derives from Service base is created).eg.
private static void Main() { var servicesToRun = new ServiceBase[] { new MyService1(), new MyService2() }; ServiceBase.Run(servicesToRun); }
If you do not do this, say you do not include code to create instance of MySerivce2, as above, you will get the error message above when you try to start MyService2.