bucketbuster Posted April 25, 2004 Posted April 25, 2004 Hi,I want to search all my drives and partitions (including subdirs and hidden folders)for *.bak and *.tmp-files using a batch file.Is this possible and how can I do that?Is there a searchcommand that can be used in a batchfile?Thanks
bucketbuster Posted April 25, 2004 Author Posted April 25, 2004 Okay thanks,is it also possible to delete them afterwards?
ToBe Posted April 25, 2004 Posted April 25, 2004 (edited) oops, posted wrong, sorry.... Edited April 25, 2004 by ToBe
evilvoice Posted April 25, 2004 Posted April 25, 2004 del /F /S /Q *.tmp/P Prompts for confirmation before deleting each file./F Force deleting of read-only files./S Delete specified files from all subdirectories./Q Quiet mode, do not ask if ok to delete on global wildcard/A Selects files to delete based on attributesattributes R Read-only files S System files H Hidden files A Files ready for archiving - Prefix meaning not
bucketbuster Posted April 26, 2004 Author Posted April 26, 2004 So when I put this in a batch file it will delete all *.tmp-files on C:\and all the subdirectories?del /F /S /Q C:\*.tmp
evilvoice Posted April 26, 2004 Posted April 26, 2004 it should, yes...do a test first though...you may have to do thisc:cd\del /F /S /Q *.tmp
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now