Auto shutdown

  • Thread starter Thread starter Rithy Chhan
  • Start date Start date
R

Rithy Chhan

Hello,

How to make Windows XP shutdown at specific time? For example we play music
at night, we want it turn off by itseft in 1 hour more!

Thanks

Rithy
 
Hello,

How to make Windows XP shutdown at specific time? For example we play music
at night, we want it turn off by itseft in 1 hour more!

Thanks

Rithy

Click Start, Run. In the Run box, copy & paste the following and click OK.

%SystemRoot%\System32\Shutdown.exe -s -f -t 3600


3600 is the number of seconds in an hour. Adjust according to your needs...
 
Thank you! And one more thing, how to cancel if we want to change the time
or we want to stop the shutdown process? How to hide this dialogue box?
 
Thank you! And one more thing, how to cancel if we want to change the time
or we want to stop the shutdown process? How to hide this dialogue box?
You're welcome.

To abort: %SystemRoot%\System32\Shutdown.exe -a

To hide the dialogue box, you'll need to use a batch file and run it from your task scheduler.

@ECHO OFF
%SystemRoot%\System32\Shutdown.exe -s -f -t 00
CLS
EXIT



From a command prompt, type: shutdown /? to see a list of command options

Usage: shutdown [-i | -l | -s | -r | -a] [-f] [-m \\computername] [-t xx] [-c "comment"] [-d
up:xx:yy]

No args Display this message (same as -?)
-i Display GUI interface, must be the first option
-l Log off (cannot be used with -m option)
-s Shutdown the computer
-r Shutdown and restart the computer
-a Abort a system shutdown
-m \\computername Remote computer to shutdown/restart/abort
-t xx Set timeout for shutdown to xx seconds
-c "comment" Shutdown comment (maximum of 127 characters)
-f Forces running applications to close without warning
-d [p]:xx:yy The reason code for the shutdown
u is the user code
p is a planned shutdown code
xx is the major reason code (positive integer less than 256)
yy is the minor reason code (positive integer less than 65536)
 
Sorry I still cannot hide the dialogue box! Please help me again. I

"To hide the dialogue box, you'll need to use a batch file and run it from
your task scheduler.
@ECHO OFF
%SystemRoot%\System32\Shutdown.exe -s -f -t 00
CLS
EXIT"

Please tell me how to follow your instruction above?

Rithy

Unk said:
Thank you! And one more thing, how to cancel if we want to change the time
or we want to stop the shutdown process? How to hide this dialogue box?
You're welcome.

To abort: %SystemRoot%\System32\Shutdown.exe -a

To hide the dialogue box, you'll need to use a batch file and run it from
your task scheduler.

@ECHO OFF
%SystemRoot%\System32\Shutdown.exe -s -f -t 00
CLS
EXIT



From a command prompt, type: shutdown /? to see a list of command options

Usage: shutdown [-i | -l | -s | -r | -a] [-f] [-m \\computername] [-t xx]
[-c "comment"] [-d
up:xx:yy]

No args Display this message (same as -?)
-i Display GUI interface, must be the first option
-l Log off (cannot be used with -m option)
-s Shutdown the computer
-r Shutdown and restart the computer
-a Abort a system shutdown
-m \\computername Remote computer to shutdown/restart/abort
-t xx Set timeout for shutdown to xx seconds
-c "comment" Shutdown comment (maximum of 127 characters)
-f Forces running applications to close without warning
-d [p]:xx:yy The reason code for the shutdown
u is the user code
p is a planned shutdown code
xx is the major reason code (positive integer less than 256)
yy is the minor reason code (positive integer less than 65536)
 
Sorry I still cannot hide the dialogue box! Please help me again. I

"To hide the dialogue box, you'll need to use a batch file and run it from
your task scheduler.

Please tell me how to follow your instruction above?

Rithy
Double-click "My Computer"
Double-click the C drive.
In the window that opens, right-click a blank ares and select "New text document".
Double-click the "New text document.txt". It will open with Notepad.
Copy and paste the following into the new document:

@ECHO OFF
%SystemRoot%\System32\Shutdown.exe -s -f -t 00
CLS
EXIT

Click "File", "Save"

Right-click "New Text Document.txt" you just created.
Select "Rename"
Rename it to "Shutdown.bat"
Answer "Yes" when it asks you if you want to change the type of file.

Click Start, Settings, Control Panel, Scheduled Tasks.
Click "Add Scheduled Task"
The Schedule Task Wizard will open
Click "Next"
It will taka a few seconds to load programs you might want to run. Wait for it...
Click the "Browse" button
Navigate to the C:\Shutdown.bat" file, click it once and click the "Open" button.
Check the "Daily" box, then the "Next" button.
Set the Start time and start date for your shutdown
Click "Next"
I think you can complete it from here. Just follow the prompts.
 
Thanks

Unk said:
Double-click "My Computer"
Double-click the C drive.
In the window that opens, right-click a blank ares and select "New text
document".
Double-click the "New text document.txt". It will open with Notepad.
Copy and paste the following into the new document:

@ECHO OFF
%SystemRoot%\System32\Shutdown.exe -s -f -t 00
CLS
EXIT

Click "File", "Save"

Right-click "New Text Document.txt" you just created.
Select "Rename"
Rename it to "Shutdown.bat"
Answer "Yes" when it asks you if you want to change the type of file.

Click Start, Settings, Control Panel, Scheduled Tasks.
Click "Add Scheduled Task"
The Schedule Task Wizard will open
Click "Next"
It will taka a few seconds to load programs you might want to run. Wait
for it...
Click the "Browse" button
Navigate to the C:\Shutdown.bat" file, click it once and click the "Open"
button.
Check the "Daily" box, then the "Next" button.
Set the Start time and start date for your shutdown
Click "Next"
I think you can complete it from here. Just follow the prompts.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top