Standard gracefull termination) then the Restart Manager will not attempt to restart the application. If the application is forcefully shutdown, (not a The Windows Restart Manager, introduced in Windows Vista, supports restarting applications after a system shutdown if they have been registered for restart with the RegisterApplicationRestart API. If you need to make a change, cancel the first command with shutdown /a Restarting Registered Applications If two shutdown commands are issued against the same computer, the first command will run and the second will fail with errorlevel 1190. If the computer is manually restarted before the schedule set with Shutdown.exe, the scheduled shutdown will be cancelled. System Tray alerts can be disabled/hidden by the user.Īlso, if the computer goes to sleep (due to Power management) before the shutdown actually occurs, then the countdown will resume after the machine is re-awakened - so the delay is running time not clock time.įor these reasons, setting a delay longer than 10 minutes (600 seconds) is not recommended. =3 mins and 10 mins and =11 mins - A system tray alert (with custom message) appears immediately, and then a generic popup alert 10 mins before shutdown. Shutdown will display one or two alert messages to the user depending on the delay (set with /t) as follows: (If not it will be ignored and logged as unplann Ed.) Alert Messages to logged in users
FORCE SHUTDOWN WINDOWS 7 CODE
Xx = The Major reason code (0-255) see below.įor a User defined Reason the Major reason code must be in the range 64-255, If neither p nor u is specified the restart or shutdown is unplann Ed. The following table lists the different values. List the reason code for the shutdown or restart. This will appear onscreen before the shutdown, and in the Windows event log comment. c " Hello" An optional shutdown message The /f parameter is implied when a value greater than 0 is specified for /t The valid range for xxx is 0- 315360000 seconds (10 years) t xxx Time until system shutdown in seconds. m \\ Computer A remote computer to shutdown or restart. o Go to the advanced boot options menu and restart the computer. fw Combine with a shutdown option to cause the next boot to go to the This will ask programs to close and wait for them to end. soft Perform a 'soft' shutdown/restart/logoff.
So will result in a loss of any unsaved data. This will not prompt for File-Save in any open applications. hybrid Perform a shutdown of the computer and prepare it for fast startup. e Document the reason for an unexpected shutdown of a computer. h Hibernate the local computer (can be used with /f ) p Turn off the local computer with no time-out or warning a Cancel a system shutdown during the time-out period. g Shutdown and Restart, after restarting restart any registered applications. sg Shutdown and on the next boot restart any registered applications. This cannot be used with /m or /d option. i Display the GUI (must be the first option)