Beispiel #1
0
        protected override void OnStop()
        {
            refMgr.StopReflector();

            // Close the server channel.
            if (channel != null)
            {
                channel.StopListening(null);
                ChannelServices.UnregisterChannel(channel);
            }
        }
 static void StopService()
 {
     if (refMgr.IsRunning)
     {
         refMgr.StopReflector();
         Console.WriteLine(Strings.ServiceStoppedSuccessfully);
     }
     else
     {
         Console.WriteLine(Strings.ServiceIsNotRunning);
     }
 }
Beispiel #3
0
 static void StopService()
 {
     if (refMgr.IsRunning)
     {
         refMgr.StopReflector();
         Console.WriteLine("Service stopped successfully.");
     }
     else
     {
         Console.WriteLine("Service is not running.");
     }
 }
Beispiel #4
0
 protected override void OnStop()
 {
     refMgr.StopReflector();
     adminForm.Dispose();
     Application.Exit();
 }