I'm trying to set up a batch file that will defragment my computer,
create a time log when it finishes, and then shutdown. I'm wondering if
my laptop will go to sleep during this process since it is set to sleep
after 15 minutes of being idle when plugged in. If so, how can I prevent
this so that the batch file can complete? This is my code so far and I'm
running on Vista:
@ECHO OFF
REM Defrag C: drive, with full defrag and forced in nec.
START "" /WAIT %SystemRoot%\SYSTEM32\DEFRAG C: -W -F
REM Creating log file of time.
ECHO. |TIME > TIME
COPY LOG +TIME
REM Now shut down, forcing apps closed if necessary
START "" /WAIT %SystemRoot%\SYSTEM32\SHUTDOWN /S /F
:END
(If something doesn't seem right in the code, please let me know).
Thanks in advance!
--
hannaxbear
------------------------------------------------------------------------
hannaxbear's Profile:
http://forums.techarena.in/members/hannaxbear.htm
View this thread:
http://forums.techarena.in/vista-help/1021113.htm
http://forums.techarena.in