Shutting Down/Restarting Windows |
(Windows Only)
|
Thanks to Scott and xbury.cs I've been able to do it with commands found on the web page which xbury.cs provided.
http://www.aumha.org/a/shtrstrt.phpBelow is a paraphrase of the important stuff copied from the site (see the above site for details):
For Windows 95
For Windows 98/ME
TO RESTART: get shell("c:\windows\rundll.exe user.exe,exitwindowsexec")
TO SHUTDOWN: get shell("c:\windows\rundll32.exe user,exitwindows")
Note: These are additive to allow you to do more than one at once. See the web site for more details.
TO LOGOFF: get shell("c:\windows\rundll32 shell32.dll,SHExitWindowsEx 0")
TO SHUTDOWN: get shell("c:\windows\rundll32 shell32.dll,SHExitWindowsEx 1")
TO RESTART: get shell("c:\windows\rundll32 shell32.dll,SHExitWindowsEx 2")
TO FORCE SHUTDOWN: get shell("c:\windows\rundll32 shell32.dll,SHExitWindowsEx 4")
TO POWEROFF: get shell("c:\windows\rundll32 shell32.dll,SHExitWindowsEx 8")
TO RESTART EXPLORER: get shell("c:\windows\rundll32 shell32.dll,SHExitWindowsEx -1")
For Windows 2000/XP
TO RESTART WINDOWS: get shell("shutdown -r -t 01")
TO SHUTDOWN WINDOWS: get shell("shutdown -s -t 01")
TO POWEROFF: get shell("c:\windows\system32\tsshutdn.exe 0 /DELAY:0 /POWERDOWN")