Beispiel #1
0
 public void Start()
 {
     //TODO: friggin 2008 LUA-must run as admin
     var t = new WinServiceStopTask(Environment.MachineName, "MSMQ");
     DeploymentResult o = t.VerifyCanRun();
     t.Execute();
     var t2 = new WinServiceStartTask(Environment.MachineName, "MSMQ");
     t2.Execute();
 }
Beispiel #2
0
 public void Remote()
 {
     //TODO: friggin 2008 LUA-must run as admin
     var t = new WinServiceStopTask("SrvTestWeb01", "MSMQ");
     DeploymentResult o = t.VerifyCanRun();
     t.Execute();
     var t2 = new WinServiceStartTask("SrvTestWeb01", "MSMQ");
     t2.Execute();
 }