How can I delete all files/subdirs except for some files in DOS? - Stack Overflow
YOu can set the attributes of the files you want to keep to readonly and hidden first, delete the rest, and then reset the attributes of the hidden, readonly files back. attrib +r +s *.bat del *.* attrib -r -s *.bat I used to do that quite often, and wrot...