using a batch file, how can i delete all files not in the windows dir?

Posted by simondo on Stack Overflow See other posts from Stack Overflow or by simondo
Published on 2010-05-20T16:15:23Z Indexed on 2010/05/29 7:12 UTC
Read the original article Hit count: 133

Filed under:
|
|
|
|

i have a litle project for which i would like to remove all files outside of and not needed by the c:\windows operating system. therefore i need to create a list of what i want to keep i.e. boot.ini c:\windows etc and then delete everything else. i have seen examples using forFile, but i can be sure that extension will be on the machine. does anyone have any ideas how i can create the exclude list and then do the delete?

© Stack Overflow or respective owner

Related posts about file

Related posts about batch