a scrpt to delete folder contents and more

moonrose

Active Member
Reaction score
4
k so i want to make a script to delete the contents of a folder, i know very little to nothing about scripting FYI.
so i found this script:

@echo off
del /q "c:\example\*.*"
exit

which will delete the contents of a folder, but if i wanted to make it delete more folders would i just add that in too? like this:


@echo off
del /q "c:\example\*.*"
del /q "c:\example1\*.*"
del /q "c:\example2\*.*"
exit

and also what if i had stuff in the folder that cant be deleted cause there in use, like any commands to ignore those type of files so the script can continue to delete everything else in that folder?

thank you very much
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top