> -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On Behalf Of > Brad Wilson > Sent: dinsdag 30 november 2004 21:54 > To: NAnt Users > Subject: Re: [Nant-users] Service Status > > Are you waiting for the service to actually stop? When you call > ServiceController.Stop(), it's really just issuing the stop command. > You'll need to loop, calling .Refresh() and then checking .Status.
Brad, the ServiceController task actually uses : serviceController.WaitForStatus(ServiceControllerStatus.Stopped, TimeSpan.FromMilliseconds(Timeout)); That should do the job right ? Gert ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/ _______________________________________________ Nant-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-users