Starting service from another
C#
2
Posts
2
Posters
0
Views
1
Watching
-
Hi, I want to debug my service, from Onstart() and in MSDN says we need to create another service (dummy) to call the main service, which I need to debug. How to call a service from another service?? Regards, Satya
Actually, you can use any application and then use the
ServiceController
to reference and start your service. This allows you time to attach to a process (or start the process that starts your service) so that you can debug the service all the way fromOnStart
. If you don't do it this way, all you can do is attach to a running process (your service). By the time the process has started,OnStart
has already been called. That's the reason for a separate process to start the service.Microsoft MVP, Visual C# My Articles