Jump to content

Recommended Posts

Posted

The school has a Functional Skills exam coming up and I need to delete the contents of the exam users folders. I have tried the following command but it only deletes files and not folders. Is there anyway I can force it to delete everything?

 

DEL /Q /S "E:\Users\ExamUsers\Exam51\*.*"
DEL /Q /S "E:\Users\ExamUsers\Exam52\*.*"
DEL /Q /S "E:\Users\ExamUsers\Exam53\*.*"

Etc..

 

I don't want to delete the top level folder (i.e. Exam51, 52 etc) just empty out the contents.

Posted

Just a quick and dirty way you could use robocopy

 

robocopy "source" "E:\Users\ExamUsers\Exam51" /MIR

robocopy "source" "E:\Users\ExamUsers\Exam52" /MIR

 

Make the source folder empty.

 

We use this for sending files to the functional skills home areas, so might be handy for that.

  • Thanks 1
Posted
Just a quick and dirty way you could use robocopy

 

robocopy "source" "E:\Users\ExamUsers\Exam51" /MIR

robocopy "source" "E:\Users\ExamUsers\Exam52" /MIR

 

Make the source folder empty.

 

We use this for sending files to the functional skills home areas, so might be handy for that.

 

Thanks, I will try that!

 

Del only does files. Think it's RD for folders?

 

e.g. RD /S /Q "path"

 

Steve

 

I've tried RD, but it removes the root folder too! Don't want that! :p

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...