In Windows 10, you can use different methods to stop, restart, hibernate or sleep the operating system. However, if you need to create a shortcut to perform one of these actions directly, the operating system does not give you this option. You must create these shortcuts manually, using a special set of commands. Here is how it can be done.
Before continuing, you might be interested to know that it is possible to create a shortcut to the good old classic Shut Down Windows dialog. We have shown how it can be done here:
How to create a shortcut to the Shut Down Windows dialog box in Windows 10
Create shortcut shutdown in Windows 10
- right click on the desktop and select New - Shortcut .
- In the target shortcut, type or paste the following command:
shutdown / s / t 0
See the following screenshot:
- Set the desired icon and name for your shortcut.
By default, shutdown / s / t 0 command will do a full stop . This means that the Quick Start function will not be used the next time you start your computer. If you use Fast Start, you must modify the stop command and add the / hybrid as
shutdown / s / hybrid / t 0
Create restart shortcut in Windows 10
to create a shortcut to restart Windows 10, use the shutdown / r / t 0 command as follows:
- right click on the desktop and select New - Shortcut .
- In the target shortcut, type or paste the following command:
shutdown / r / t 0
See the following screenshot:
- Set the desired icon and name for your shortcut.
sleep shortcut for Windows 10
The command to put the computer to sleep is as follows:
rundll32. exe powrprof.dll, SetSuspendState 0,1,0
However, if you have enabled hibernation, which is enabled by default on most computers, the command will put your PC into hibernation instead . I explained in detail here: How to sleep Windows 10 from the command line
So you can create a batch file "sleep.cmd" with the following contents :.
powercfg -h off rundll32. exe powrprof.dll, SetSuspendState 0,1,0 powercfg -h on
In the example above, I used the powercfg command to disable hibernation just before you use the command Rundll32. Then the rundll32 command will work correctly and put the PC to sleep
Suppose that you saved the command file in the c :. Apps. Then you create a shortcut to Windows 10 put to sleep this way:
- Right click the desktop and select New - Shortcut .
- In the Target box of the shortcut, type or paste the following command:
c: apps sleep.cmd
Correct the file path according to your preferences.
- Set the desired icon and name for your shortcut.
Hibernate Shortcut for Windows 10
As mentioned above, when the hibernation is enabled, the same command hibernate your PC to create the file following commands:
powercfg -h on powrprof.dll rundll32.exe, SetSuspendState 0,1,0
he will hibernation if it has been disabled and Windows 10 PC hibernates .
Log, such as c: apps hibernation.cmd
Then, create a shortcut to that file.
Here are other items you might be interested in:
- How to set the default action for the stop dialog box in Windows 10
- All restarting means and stop Windows 10
- the slide-to-shutdown feature in Windows 10
- Speed up slow shutdown in Windows 10
Here. If you have questions or suggestions, you are invited to comment.
0 Komentar