Originally posted by: Muse
Originally posted by: Muse
Originally posted by: 2canSAM
Paste this into notepad and save as shutdown.bat, make sure you select all file types to force it to save as a batch file and not a txt file.
c:\windows\system32\shutdown.exe -s -f -t 10
Then point Task Scheduler to the batch file and run it as Administrator. I just tested this logged on a restricted user and it ran just fine. The -s means to shutdown (replace with -r if you want the pc to reboot) the -f means force an unresponsive application to close and the -t 10 means delay the shutdown 10 seconds. A message will pop up saying the system is shutting down in 10 seconds and who initiated it, this should be the administrator account of your PC.
That's a thing of beauty. Thanks!
I ran it and it worked. I had 10 seconds but no option to cancel the shutdown, which would be nice.
I'm curious about the saving it as All File type and not a text file. I thought that as long as the file extension was .bat it would run as a batch file automatically even if created in a text editor. I did as you said, but wouldn't it have worked if I just saved as a text file and then made sure the extension was .bat?