Quantcast
PCWorld.com is upgrading some back-end systems. Some site features, such as user registration, may be temporarily unavailable.

Windows Tips: What's on the Menu? You Decide

Customize menus and accelerator keys; force Windows to exit or reboot.

Scott Dunn

  • 0 Yes
  • 0 No

Force Windows to Exit or Reboot

In January's Windows Tips, I showed how to create shortcuts that automate the process of shutting down Windows or rebooting your computer. But a problem arises if your PC is on a network: Shutting down Windows in that situation can trigger a message box reminding you that you are connected to another computer. Windows then asks for permission to proceed. If you're using Task Scheduler to automate a shutdown or reboot, you may not be at your PC to respond, so Windows will simply sit there with the prompt displayed for all eternity--or at least until someone responds by clicking Yes or No. So much for automation.

Fortunately, as Richard Schauer of Everett, Washington, points out, you can force Windows to shut down or reboot and have it ignore all open applications, documents, and message prompts. First, if you haven't already done so, create your shutdown or reboot shortcut: Right-click the desktop or in the desired folder and choose New, Shortcut. Type the appropriate command line, but add 4 to the numeric parameter at the end.

For example, the command line normally used for shutting down Windows is 'rundll32.exe shell32.dll,SHExitWindowsEx 1'. Add 4 to the final parameter, and now the 'force shutdown' line becomes 'rundll32.exe shell32.dll,SHExitWindowsEx 5'. To force a reboot, change the '5' to a 6 (equivalent to adding 4 to the normal reboot option of 2). To complete the shortcut, click Next, type a name, and click Finish.

Characters in this command line are case-sensitive, so watch your capitalization. Also, take care not to add a space after the comma. A typo in the January issue included a space, to the consternation of many readers. Deleting the space should solve that problem.

The downside: If you use this command, Windows will ignore all network connection prompts and also any prompts to save open documents. If any open documents have unsaved changes when you force a shutdown, those changes will be lost for good. So use this technique only when you're certain you won't lose data.

  • Recommend this story?
  • 0 Yes
    0 No
  • Great year-end deals
    for small business!
  • Get 24/7 live remote AT&T Tech Support 360* service along with select Lenovo* PCs (with Intel® Core™ 2 Duo processors) and save up to 200!

    Learn more

  • HP EliteBook* 6930p Notebook with Intel® vPro™ technology and a free HP Basic Docking Station - $641 instant savings!

    Learn more

Dell End of Year Deals

Focus on Personal Productivitysponsored by Microsoft

  • Personal Finance 2.0 These free and fee-based Web services not only aggregate data from your online bank accounts, they give you tools for managing your money.
  • High-Tech Travel Tips Plenty of stories provide advice for elite mobile professionals. But what about you, the unproductive traveler?

People who read this also read:

Sponsored Links