You can create desktop shortcuts to shutdown Windows, or to restart Windows, with a single click. You can place these shortcuts any place you like---the desktop, the Quick Launch Bar, you Start Menu-whatever. To do this:
1. Right mouse click on an empty part of the desktop. Select New \ Shortcut.
2. A "wizard will pop up to guide you through the rest of the process. In the Command line box,
type in the Command line of what you want to accomplish (I have Restart Windows in the one
3. Then provide a name for the Shortcut. The name can be anything you want.
There are two sets of commands you can use to accomplish these tasks: The Short version, and the Long version. Both are listed below.
The Short Version
The shortcut command line should be as follows (just copy and paste the text into the shortcut command line box):
For a shortcut to RESTART Windows:
For a shortcut to SHUT DOWN Windows:
The Long Version
The command line should be as follows:
C:\WINDOWS\RUNDLL32 HELL32.DLL,SHExitWindowsEx n
Where n is one of the following values, depending on the task you want to accomplish is:
n=0 LOGOFF: Shuts down all running processes, logs the user off, then restarts the Windows
shell. (Same as Logoff on the Start Menu).
n=1 SHUTDOWN: Shuts down the system at a point which it is safe to turn off the power. All file
buffers have been flushed to the disk, and all running processes have stopped.
n=2 REBOOT: Shuts down the system, then restarts it (same as the Start Menu \ Shutdown \
n=4 FORCE: Forces all processes to terminate-in effect, shuts down all running programs. When
this flag is set, Windows does not query running applications to lose data, therefore you
should only use this flag in an emergency.
n=8 POWER OFF: Exits Windows, then turns off the computer's power (provided the computer
supports the power-off feature).
n=-1 RESTART EXPLORER: Quickly closes Explorer (i.e., the Windows desktop), then lets it
These values are additive (though I have yet to find an occasion where I would want to do two of them at once).
Back To General Information