Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
Batch delete files on external HD
Name: hobblyhoy Date: June 29, 2007 at 00:07:16 Pacific OS: winXP CPU/Ram: 512 Product: HP
Comment:
I'm trying to create a batch that removes all .DS_store files located on an external harddrive. Unfortunately I've hit 2 roadblocks. For one, I can't CD to the to the external as windows wont allow it, so
del /F /S /Q *.DS_store
is out of the questions, and using:
del /F /S /Q K:\*.DS_store
Will only delete the DS files located in the root of the drive, not any of the subdirectorys. HELP!
~Nathan Rooke
"the right to swing my arm ends where your nose begins." -Claude Adrien Helvetius
Name: Razor2.3 Date: June 29, 2007 at 01:19:36 Pacific
Reply:
Before your del line, add: K:
0
Response Number 2
Name: Mechanix2Go Date: June 29, 2007 at 01:59:13 Pacific
Reply:
"del /F /S /Q K:\*.DS_store"
That is correct syntax.
If it doesn't work you may have a currupt file system. If you can't CD to the drive [unecessary for DEL] you may have serious problems.
===================================== If at first you don't succeed, you're about average.
M2
0
Response Number 3
Name: hobblyhoy Date: June 29, 2007 at 12:29:07 Pacific
Reply:
Wow. your actually right mechanix. I came back and ran the same script from yesterday and it just randomly decides to work today. Maybe since I was running it based off the errorlevel of the command before it?
Oh well, works now. Thanks all :D
"the right to swing my arm ends where your nose begins." -Claude Adrien Helvetius
Summary: Hi. I'd like to batch delete files in a selected directory(incl. subdirectories too) based on .txt on ftp. In a local site, I can do it by making .bat like this: -- set dir1=w:\docs\manual\ : for /F ...
Summary: Ello again, Well i want to know if a batch file (or something else like vbs) can del all files off remote computers but save one folder that has important data in it in a root drive call D:? This is f...
Summary: I have share on a server in which i have files being saved to. I need to purge this folder every so often of files that are no older then 2 days. I have found a batch file to do this. How ever on the ...