How to use Win7 to start and stop Windows service program

  

There are many ways to start a stop service:

Some programs provide a setup interface that can be set to start and stop. Some third-party programs can also be used to control start-stop. For example, a certain guardian and the like; can also specify the service program to start and stop through the service management of the windows system; however, these methods are too troublesome to operate, if you need to frequently switch to start and stop, the above operation modes are somewhat It’s a very convenient way to start and stop through the command line. Using the command line is also very simple, let's get into the actual operation.

The method/step is as follows:

1. Right click on the desktop <; Computer> Select “Manage” menu item.

2. After clicking the “Manage” menu, the computer management window will open. In the tree list on the left, click the “Services” node. The right side of the window is a list of system service items, with service name, service description, status, etc., where you can terminate the service and adjust the service startup mode. Below, we take the "MSSQLSERVER" service in the red circle in the figure as an example.

3. After selecting the service in the service list, click the right mouse button and select the “Attributes” menu in the pop-up menu to open the Properties window.

4, the purpose of opening the property window, mainly to get the service name, because the name seen in the list is called "display name", when you use the command line operation must specify the service name. In the red circle of the figure, this name can be selected with the mouse, press the shortcut key Ctrl+C to copy to the system clipboard for later use.

5, with any editor that can edit the text, the system comes with a notebook, open Notepad, paste the service name just copied to the text.

6. Add the rest of the order. Start the service with the command: NET STAR, stop the command with the command: NET STOP, supplemented in front of the service name. Start and stop respectively create a text to control start and stop.

7. Save the document in .bat format. Click the File menu in the Notepad menu and select Save. In the pop-up Save dialog box, note: Set the save type to All Files so that you can name the file suffix yourself. Of course, you can also save the file extension to the resource manager and change it to .bat. In this way, the service command line files for starting and stopping are all ready, and the service can be started and stopped conveniently. Windows7 tutorial

Copyright © Windows knowledge All Rights Reserved