Jump to content


  • 0
anyweb

how can I shutdown Windows ?

Question

you can edit a batch file (shutdown.bat) and paste the following into it

 

shutdown.exe -s -f -t 5 -c "shutting down the computer now"

 

save the file and you can 'call' it either using Windows Task Manager (start/control panael, scheduled tasks, add scheduled task)

 

the -s in the code above tells shutdown.exe to shut the system down, if you want to reboot the machine change it to -r

 

the -f switch forces running applications to close without warning and the -c displays a comment box to warn the user of the coming shutdown, in addition it adds this info the the eventviewer.

 

the 5 after -t is the number of seconds before the machine is shutdown.

 

cheers

anyweb

Share this post


Link to post
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...


×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.