Batch file. Delete all files and folders in a directory

前端 未结 14 1308
无人共我
无人共我 2020-11-30 19:20

I want to have a batch file that will delete all the folders and files in my cache folder for my wireless toolkit.

Currently I have the following:

cd         


        
14条回答
  •  遥遥无期
    2020-11-30 19:51

    Try the following; it works for me.

    I have an application which dumps data in my "C:\tmp" folder, and the following works the best for me. It doesn't even ask Yes or No to delete the data. I have made a schedule for it to run after every 5 minutes

    cd "C:\tmp"
    
    del *.* /Q
    

提交回复
热议问题