c# - Disable Windows service at application launch -
I have to close Windows Advanced Text Services in my application launch. Is there any special API for this? Will it work for the user with default rights?
service controller _ServiceController = new service controller ([NameService]); If (! _ServiceController.ServiceHandle.IsInvalid) {_ServiceController.Stop (); _ServiceController.WaitForStatus (ServiceControllerStatus.Stopped, TimespainFromMillionsCand (uConstante.CtTempoEsperaRespostaServico)); }
Comments
Post a Comment