locked
NO Hibernation just SLEEP RRS feed

  • Question

  • What is the command that EXACTLY duplcates the action of selecting "SLEEP" at the Start...Shut Down GUI. ALL the tips and tricks suggested anywhere I can find like (rundll32 powrprof.dll, Set SuspendState Standby) puts the computer into HIBERNATION, and I have to push the POWER button for it to restart. I want to be able to create a HotKey to duplicate what clicking on "SLEEP" or pushing the SLEEP key on the keyboard does. (My new keyboard doesn't have a sleep button)
    Wednesday, February 29, 2012 8:37 PM

Answers

  • You're right, these commands will put the computer into HIBER if Hibernate is enabled. You need to turn off Hibernate

    In CMD:

    $ Powercfg -H OFF

    • Marked as answer by moskinky Thursday, March 1, 2012 2:36 PM
    Thursday, March 1, 2012 2:04 PM

All replies

  • Like I said, my old keyboard had a "SLEEP" button but my new one doesn't. (I got one that is wireless and illuminated for use with my media in a darkenened room) and I want to create a HotKey that will put the computer into the same sleep mode the keyboard buttons OR the sleep mode available at the START - SHUTDOWN screen. All the sites and replies I've gotten in the past month and a half have revolved around....(rundll32.exe powrprof.dll, Set SuspendState Standby or standby) which puts the computer into HIBERNATION not the Sleep or Hybrid Sleep mode.

    The computer is a desktop with w/WIN7 and it has the option of Sleep or Hibernate or if activated Hybrid Sleep which removes the option of Hibernate on the screen BUT IT STILL GOES IN TO HIBERNATION. And that requires hitting the POWER button on the tower and takes longer to wake than just clicking the mouse or keyboard.

    Nobody seems to know how to do this!

    Thursday, March 1, 2012 1:32 AM
  • I know how to "remap" the keys ! I have re-assigned 12 so far on this keyboard (eclipse lite-touch, look it up) But in order to do that, you have to know the "command" you want associated with that key. That's what you are not getting from my posts. The command proposed by everyone that has responded or that I can find anywhere (rundll32.exe powrprof.dll, Set SuspendState Standby) does not put the computer into SLEEP mode as touted it puts it into HIBERNATION, WHICH IS NOT ACCEPTABLE!

    If I reconnect my old, wired keyboard I have the SLEEP button, but I don't have the illuminated wireless flexibility. And I have the ability to go to the Start menu and click on sleep, which places the computer in the correct SLEEP mode. EXCEPT when I have no monitor to SEE the screen, to find the start menu. (This occurs when the TV/monitor is being used by BluRay or Live TV)

    I just need to know what the what the friggin' command line is that puts the computer into the SLEEP mode that allows it to be awakened with mouse movement, NOT THE POWER BUTTON!

    Thursday, March 1, 2012 12:38 PM

  • Read this thread:

    http://answers.microsoft.com/en-us/windows/forum/windows_vista-desktop/desktop-shortcut-for-the-sleep-command/4e57f536-50a8-4942-a84a-290b3dea1ffb

    Simply put, it's

    Rundll32.exe Powrprof.dll,SetSuspendState Sleep

    How you wake it up is controlled partially by your BIOS settings (to allow a keystroke or mouse click to wake it up), and in you device settings for the mouse and keyboard from within your Power profile settings.

    Depending on your KB make and model, there may be programmable keys that you can assign a shortcut. Or, after you create a shortcut for Sleep, open its Properties and go to the Shortcut tab. About halfway down is a line for Shortcut Key. Put what you want in there. Just be careful that it's not a series of keystrokes that's already assigned to something else in Windows.

    http://windows.microsoft.com/en-US/windows7/Keyboard-shortcuts


    SC Tom

    Thursday, March 1, 2012 12:58 PM
  • I really appreciate you trying to help, but please read my post directly above yours. The 2 links you list were the 1st place I looked for an answer.

    Simply put, the (....SetSuspendState Sleep) or (.....SetSuspendStateStandby) DO NOT WORK! they put the computer in HIBERNATE mode, NOT SLEEP or HYBRID SLEEP mode. In the SLEEP mode that is created by the KB button or at the START menu the computer powers down a little, placing your info in RAM,the power light blinks, the monitor sleeps and everything can be awakened quickly with mouse movement or KB (depending on BIOS settings)

    In HIBERNATE mode, the computer powers way down, putting your stuff on the hard drive, the power light turns off, the monitor sleeps and you are required to hit the power button to wake the computer, which acts like it's re-booting without requiring a login, and it takes a while.

    Using (Rundll32.exe Powrprof.dll,SetSuspendState Sleep) puts the computer into HIBERNATION not SLEEP

    I need the SLEEP mode that that is effected with the KB button or at the START menu.

    Thursday, March 1, 2012 1:37 PM
  • You're right, these commands will put the computer into HIBER if Hibernate is enabled. You need to turn off Hibernate

    In CMD:

    $ Powercfg -H OFF

    • Marked as answer by moskinky Thursday, March 1, 2012 2:36 PM
    Thursday, March 1, 2012 2:04 PM

  • <moskinky> wrote in message news:95a98ca6-606a-4e6d-a694-09a3c4ed4604@communitybridge.codeplex.com...

    I really appreciate you trying to help, but please read my post directly above yours. The 2 links you list were the 1st place I looked for an answer.

    Sorry, didn't see that in any of your posts. Nor did I see anywhere that you tried "....SetSuspendState Sleep".

    From what I have read, in order for Sleep to work from command line, hibernation has to be disabled first. Then the PC will go into Sleep mode instead of Hibernation.

    (BTW, I know the difference between Sleep, Hibernation, and Hybrid Sleep. :-)  )


    SC Tom

    Thursday, March 1, 2012 2:13 PM
  • I'm sorry if I was terse. It has been frustrating. I didn't mean any disrespect. Please read my response to fanfarenj
    • Proposed as answer by Noel Jones Tuesday, December 30, 2014 12:12 PM
    • Unproposed as answer by Noel Jones Tuesday, December 30, 2014 12:26 PM
    Thursday, March 1, 2012 2:37 PM
  • THANK YOU SO MUCH!! That was it! I knew that Hibernate had to be turned off and I had gone into the "Power Options" section of the control panel and turned it off there. Obviously that ain't where ya do do it!

    It is now sleeping like it it should.

    Now I have to figure out why from time to time the mouse pointer, or programs that are running start freezing for a split second, until I reboot. I feel like it's a caching/memory thing but I've got 4g of RAM. Could it be insufficient power supply?

    Thanks again!

    • Proposed as answer by Noel Jones Tuesday, December 30, 2014 1:11 PM
    Thursday, March 1, 2012 2:45 PM
  • Even though the original inquiry is almost 3 years old, the following details of my experience with powrprof.dll may assist somebody. I am currently running Windows 8.1 Pro 64.

    As stated in earlier replies, C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0 does not perform Sleep or Hybrid Sleep unless Hibernate is turned OFF. Instead, it enters into Hibernate state.

    However the command C:\Windows\System32\psshutdown.exe -d -t 0 does allow the computer to enter Sleep (Suspend) even when Hibernate is still turned ON. This then acts like the Sleep that is contained in the Power ON/OFF button, or the "Shut down or sign out" option of the START (lower left of Desktop taskbar). With Hibernate still enabled, both Sleep and Hibernate are available shutdown options.

    PsShutdown.exe is contained within Windows Sysinternals that can be easily downloaded from Microsoft.

    Tuesday, December 30, 2014 1:18 PM
  • Got It...Made Working Sleep cmd Using Above  PsShutdown.exe

    Download From Here: 
    https://technet.microsoft.com/en-us/sysinternals/psshutdown.aspx

    Put The PsShutdown.exe into C:\Windows\System32\

    Put The Following Line Into Your notepad

    psshutdown.exe -d -t 0 -accepteula

    The "-accepteula" Is To Accept The Terms Screen That Pops Up When Executing psshutdown.exe -d -t 0

    And Save Your New Sleep cmd File



    Wednesday, January 18, 2017 5:05 AM