how to add a shortcut to shutdown computer?

Discussion in 'Windows Desktop Systems' started by rhenk, Apr 1, 2002.

  1. rhenk

    rhenk Guest

    I want to create a shortcut in the desktop so I can directly shutdown the computer. How can I do? In the Tweak section it explains how to create a shortcut to lock computer ("rundll32.exe user32.dll,LockWorkStation") but it doesn't shutdown the computer, it closes the open session. So how can I do to create a shortcut to close directly the computer? Thanks.
     
  2. Qumahlin

    Qumahlin Moderator

    Messages:
    2,006
    I had this in a tweaks file on my comp..it is from another site but I don't know where so sorry for not giving credit.

    Be advised that using this will not auto "turn off" the computer..just shut it down. I don't yet know how to use the shutdown command to make the appropriate ACPI call to turn off the computer. Although if you use ACPI and your tower is nearby you, you can always use power options to make it so when you press the button on the tower it shurts down then turns off :)


    Right click on an open area of the desktop
    Select New / Shortcut
    Enter in "shutdown -s -t 00" - no quotes
    Press the Next button
    For the name, enter in anything you like. I just use shutdown. Click on the Finish button.

    For a reboot, enter "shutdown -r -t 00"
    For a logoff, enter "shutdown -l -t 00"


    Shutdown [{-l|-s|-r|-a}] [-f] [-m [\\ComputerName]] [-t xx] [-c "message"] [-d[p]:xx:yy]

    Parameters

    -l - Logs off the current user, this is also the defualt. -m ComputerName takes precedence.
    -s - Shuts down the local computer.
    -r - Reboots after shutdown.
    -a - Aborts shutdown. Ignores other parameters, except -l and ComputerName. You can only use -a during the time-out period.
    -f - Forces running applications to close.
    -m [\\ComputerName] - Specifies the computer that you want to shut down.
    -t xx - Sets the timer for system shutdown in xx seconds. The default is 20 seconds.
    -c "message" - Specifies a message to be displayed in the Message area of the System Shutdown window. You can use a maximum of 127 characters. You must enclose the message in quotation marks.