I am Dale Hayter, a Microsoft and VMware certified Technical Consultant.

My blog has been built up over the years from my experience of working on an IT helpdesk and also from being out on-site.

Script to Delete All Subfolders

Was looking for a script to go into a specific folder and delete all folders but leave the files in the root folder.

This is the script that we used in a batch file

cd \
cd test
for /d %%a in (?*) do rd /s /q "%%a"