Re: How to delete temp files
- From: "Pegasus \(MVP\)" <I.can@xxxxxxxxxx>
- Date: Sat, 5 Jan 2008 23:03:06 +0100
You will always get "File in use" messages, because some temp
files are in use while Windows is up and running. Here is the
solution with logging added:
@echo off
echo.
echo Cleaning out the Temp directory
del /q "%temp%" 1>c:\DelTemp.txt 2>&1
notepad c:\DelTemp.txt
"DonV" <dvonj@xxxxxxxxxxx> wrote in message news:OBQ88v8TIHA.3940@xxxxxxxxxxxxxxxxxxxxxxx
Coolio thanks.
Anyway to get around the Access Denied in Vista and the file is in use by another process? In other words is the a switch that will force the deletions?
"Pegasus (MVP)" <I.can@xxxxxxxxxx> wrote in message news:eKT0Ao8TIHA.748@xxxxxxxxxxxxxxxxxxxxxxx
Here we go. Save the following lines in c:\Windows\DelTemp.bat,
then create a link to it.
@echo off
echo.
echo Cleaning out the Temp directory
del /q "%temp%"
ping localhost -n 10 > nul
"DonV" <dvonj@xxxxxxxxxxx> wrote in message news:OISALm8TIHA.1168@xxxxxxxxxxxxxxxxxxxxxxx
I would like a script that I can click on and have it delete all the files in the temp directory. It would be even more useful if the script can run on Vista as well as XP.
Anybody have such a script and how it can be used this way?
- Prev by Date: Re: Help-
- Next by Date: Script to rename workgroup win2000 pc
- Previous by thread: Re: Help-
- Next by thread: Script to rename workgroup win2000 pc
- Index(es):
Relevant Pages
|