The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 2,806 other followers

Commandlines for shutdown, reboot, logoff, standby and hibernate (from: A standby shortcut? – The PC Guide Discussion Forums)

Posted by jpluimers on 2009/06/11

Being a commandline person (I prefer to think of it as ‘classic’ more than like ‘dinosaur’), I have a ton of batch-files in my %SystemDrive%BIN directory.

Recently, I needed one for hibernating, which I found in this posting: A standby shortcut? – The PC Guide Discussion Forums.

Here is the list:

Shutdown.bat / Halt.bat %windir%System32shutdown.exe -s
Reboot.bat %windir%System32shutdown.exe -r
Logoff.bat %windir%System32shutdown.exe -l
Standby.bat %windir%System32rundll32.exe powrprof.dll,SetSuspendState Standby
Hibernate.bat %windir%System32rundll32.exe powrprof.dll,SetSuspendState Hibernate

Maybe it has some use for you too :-)


4 Responses to “Commandlines for shutdown, reboot, logoff, standby and hibernate (from: A standby shortcut? – The PC Guide Discussion Forums)”

  1. Bert Haver said

    Hi Jeroen,
    I like batchfiles too! We are using batchfiles for scripting withing our (Kaseya) PC (Windows) maintenance system.
    I’m looking for a command line sequence to remotely disable Windows powersettings. Have you ever needed/found this somewhere?

  2. mhestl said

    Since your still using batch files…As a commandline person are your familiar with Powershell?
    If not check it out (Channel9 has some cool demo’s on Powershell:

    • jpluimers said

      For smaller things, I still tend to use plain batch files.
      When it gets more complex, I use more advanced scripting tools highly depending on my environment (like OS ).
      I’m not yet completely familiar with Powershell, but that’s because of its’ vast possibilities.
      I do use it though.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: