1. Joined : Aug 2015
    Posts : 18
    Windows 10 Pro
       06 Aug 2015 #1

    Windows 10 sleep shortcut


    Hello,
    in Windows 7 I used this cmd to sleep my PC:
    rundll32.exe powrprof.dll,SetSuspendState 0,1,0 (I have hibernation disabled)
    when I pressed a key my desktop would come up instantly, but now in Windows 10 it goes all the way through POST screen, the loading screen and then I see my desktop which takes a bit longer. Interestingly if I sleep my PC with the start menu (right click power > sleep) pressing a key wakes it up instantly just like on Windows 7. What's wrong with the cmd command and how can I fix it? I really would like to have an icon on my desktop for this.
    Thanks.

    ed. ok I solved my problem by using PsShutdown
    Last edited by maxiu; 07 Aug 2015 at 01:35.
      My System SpecsSystem Spec


  2. Joined : Sep 2014
    Posts : 270
    Window 10
       15 Aug 2015 #2

    maxiu said: View Post
    Hello,
    in Windows 7 I used this cmd to sleep my PC:
    rundll32.exe powrprof.dll,SetSuspendState 0,1,0 (I have hibernation disabled)
    when I pressed a key my desktop would come up instantly, but now in Windows 10 it goes all the way through POST screen, the loading screen and then I see my desktop which takes a bit longer. Interestingly if I sleep my PC with the start menu (right click power > sleep) pressing a key wakes it up instantly just like on Windows 7. What's wrong with the cmd command and how can I fix it? I really would like to have an icon on my desktop for this.
    Thanks.

    ed. ok I solved my problem by using PsShutdown
    Could you provide the full command line you're using (for those of us that aren't quite up to speed on the PsShutdown flags)? Thank you in advance.
      My System SpecsSystem Spec


  3. Joined : Aug 2015
    Posts : 18
    Windows 10 Pro
       15 Aug 2015 #3

    D:\PSTools\psshutdown.exe -d -t 0 -accepteula
      My System SpecsSystem Spec


  4. Joined : Oct 2015
    Posts : 5
    Windows 10
       03 Oct 2015 #4

    Hello. Does anyone know how to create a desktop shortcut to invoke sleep in Windows 10 without having to run third-party software like PSTools?

    I have tried the following, but they are not the same as "sleep":
    C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0
    C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState
    C:\Windows\System32\rundll32.exe Powrprof.dll,SetSuspendState Sleep

    rundll32.exe powrprof.dll,SetSuspendState 0,1,0 makes my Win8 to hibernate (suspend-to-disk). It does not make it Suspend-to-RAM (named Sleep or Standby, depending on windows version) neither does it make go to hybrid sleep (suspend-to-RAM while at the same time save state to disk), as the Sleep option in the Shutdown menu.

    They seem to work, but it is not sleep mode, because the power button does not flash and I can't wake my PC using my mouse. I think the above commands may be hibernate; the only way to wake the PC is by pressing the power button.

    Thank you.
    Last edited by GODisaRefuge4Us; 03 Oct 2015 at 22:09.
      My System SpecsSystem Spec


  5. Joined : Oct 2015
    Posts : 5
    Windows 10
       03 Oct 2015 #5

    deleted, combined with prior post
    Last edited by GODisaRefuge4Us; 03 Oct 2015 at 22:10. Reason: deleted, combined with prior post
      My System SpecsSystem Spec


  6. Joined : Oct 2014
    Posts : 1,309
    win 10 Insider
       03 Oct 2015 #6

    I use a shortcut with this code C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState
    Start it in windows\system32
    Certainly works here.
      My System SpecsSystem Spec


  7. Joined : Oct 2015
    Posts : 5
    Windows 10
       03 Oct 2015 #7

    Thanks Linw. I had that listed in my first post, and I will use it. However, it doesn't function the same as when I right click the windows button, choose "shut down or sign out", and then select Sleep.

    With the command C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState
    1. the light on my PC power button does not flash (to indicate sleep mode); instead, the light is off
    2. I can't wake my PC by using my mouse (I have to press my PC power button)

    So, it's not the same, but it does work (i.e., it does "sleep" my PC and wake it again).

    Tenforums can archive this thread, if they like. My preference would be to find the command that acts the same as "sleep" when I select it from the windows button. Not a big deal, but it would be nice to have the same functionality. Thank you.
      My System SpecsSystem Spec


  8. Joined : Oct 2015
    Posts : 5
    Windows 10
       03 Oct 2015 #8

    I think I found the answer.

    Although I had turned-off the ability to hibernate in Control Panel/Power Options, apparently that's not enough. I also had to run the following command as administrator from a command prompt:

    powercfg -hibernate off

    After running the above command, either of the following shortcuts worked just like when I select "sleep" from the windows button:
    C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0
    C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState

    FYI.
      My System SpecsSystem Spec


  9. Joined : Oct 2014
    Posts : 1,309
    win 10 Insider
       03 Oct 2015 #9

    Ah, I always turn off hibernation.
      My System SpecsSystem Spec


 


Similar Threads
Thread Forum
Shortcut Name Extension - Turn On or Off in Windows 10
How to Turn On or Off 'Shortcut' Name Extension for New Shortcuts in Windows 10 When you right click or press and hold on a file, folder, or drive and click tap on either Create shortcut or Send to -> Desktop (create shortcut), a shortcut to that...
Tutorials
This PC Shortcut - Create in Windows 10
How to Create a This PC Shortcut in Windows 10 My Computer was changed to This PC in Windows 8.1 and Windows RT 8.1. You would open File Explorer to view This PC. In Windows 10, File Explorer now opens to Quick access by default instead of...
Tutorials
Cannot go to Sleep (S3) or even sleep the monitor for Win 10
I upgraded from 8.1 to 10 on the 29th. At that time my system would go to standby sleep without and issue. Since the big day, I can only get it to sleep by using the sleep option on the shut down or sign out drop down. I have reinstalled my...
General Support
Shortcut Windows + E
Hi! Sorry if this has been covered before, I could not find a topic to do with it in the Search function. While Using Windows 8 I got used to using many of the Windows shortcuts, Win + R etc which I think I did because I didn't fully get on...
General Support
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 16:24.
Find Us
Twitter Facebook Google+



Windows 10 Forums