Batch file to delete all MP3s from sub directories-

I need a Batch file to delete all mp3 files from all sub folders under c:\homedir\ but retain directory structure.
Students download mp3's during the day, and I would like to have a script to automatically delete all of the mp3, exe, or zip files that they shouldn't be downloading anyway-
I guess this could also be writtin in vbs but I prefer batch- Can anyone help me with this?

Also I will be running this directly from the storage server so that it can run quickly at night. This will probably deter a lot of them from moving music to my storage server-

Thanks!!
-Charlie
Boomer7638Asked:
Who is Participating?
 
Guy Hengel [angelIII / a3]Connect With a Mentor Billing EngineerCommented:
del /s C:\homedir\*.mp3
0
 
Boomer7638Author Commented:
You make it sound soo easy- Thanks for the quick reply- I may just run this twice a day and push the output to a text file named date/time.log so I will know which files were deleted (and which students are doing things they shouldn't be).

I guess that's what I get for not even looking first huh- Thanks again!
0
All Courses

From novice to tech pro — start learning today.