Timed Shortcut for sleep/hibernation?

Page 1 of 3 123 LastLast

  1. Posts : 29
    Windows 7 Home (x64)
       #1

    Timed Shortcut for sleep/hibernation?


    Hi, so I have 10,000msecond(2.7hour) shortcut to shutdown my computer ("C:\Windows\System32\shutdown.exe -s -t 10000") which i use for watching films before bed, just encase i sleep half way through but I was wondering if there was a way to make a similar shortcut but instead of making your computer shutdown in a few hours make it sleep in a few hours time.

    Now I know how to make a sleep shortcut but that makes the computer sleep instantly, and putting "-t 10000" at the end of "C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0" doesnt work. Apparently their is a way to do it if you install some software but I don't want that.

    Anyone know if its possible with just windows command shotcuts?
      My Computer


  2. Posts : 7,683
    Windows 10 Pro
       #2

    I have no ideal how to do this, wasn't even aware you could, but that's an interesting scenero.

    Be interesting to see what solutions are posted.
      My Computer


  3. Posts : 3,427
    Windows 10 Pro x64
       #3

    should work as you posted.... but you will need to disable Hybrid Sleep in Advanced Power options first
      My Computer


  4. Posts : 29
    Windows 7 Home (x64)
    Thread Starter
       #4

    so putting "C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0" into the shortcut does make it sleep, and putting -t 10000 doesnt make it timed it just does it instantly.

    Unless im doing something wrong anyone got any ideas?
      My Computer


  5. Posts : 6,885
    Windows 7 Ultimate x64, Mint 9
       #5

    Try:
    rundll32.exe powrprof.dll,SetSuspendState -t 10000 0,1,0
    or removing the 0,1,0 altogether

    ~Lordbob
      My Computer


  6. Posts : 29
    Windows 7 Home (x64)
    Thread Starter
       #6

    Lordbob75 said:
    Try:
    rundll32.exe powrprof.dll,SetSuspendState -t 10000 0,1,0
    or removing the 0,1,0 altogether

    ~Lordbob

    Nope that doesnt work either.
      My Computer


  7. Posts : 1,814
    XP / Win7 x64 Pro
       #7

    What I'd do is make a .bat file with this line in it:

    echo schtasks /CREATE /SC ONCE /TR "C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0" /SD <start-date> /ST <start-time>

    Then, say it's tonight around 11pm and you want to put the system to sleep at 1am, then <start-date> would be 6/19/10 and <start-time> would be 01:00.

    Just edit the file to reflect whatever times you want, save it, then right click and run as admin to execute it and set up the scheduled task.
      My Computer


  8. Posts : 29
    Windows 7 Home (x64)
    Thread Starter
       #8

    So that looks like it should work going to try it out in a bit but if anyone can find a way to do it without having to put them time in every time that would be awesome.
      My Computer


  9. Posts : 1,814
    XP / Win7 x64 Pro
       #9

    If it is always the same time of day/night you want it to sleep, then you can leave the time the same and omit the date and never have to change it. The problem comes if you want to shut off at 1am (e.g. a different day than current). If you just put 01:00 and no date, it won't run b/c 1am has already passed on the current day.
      My Computer


  10. Posts : 78
    Win 7/Pro 64-bit
       #10

    Sleep Mode ??


    If this: C:\Windows\System32\rundll32.exe powrprof.dll,SetSuspendState 0,1,0
    get my Windows 7 machine to hibernate via a shortcut icon on my desktop,
    which it does on both 32- and 64-bit machines, then what gets it to go into "sleep" mode?
      My Computer


 
Page 1 of 3 123 LastLast

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 23:28.
Find Us