Delete contents of a folder tree with a kill statement

210 pts.
Tags:
Batch files
Batch jobs
VB script
Visual Basic Script
Would anyone know of a code, or be able to point me to one, that will delete all files and folders under a given location.  I am looking to schedule the empting of temp folders and would like it to be all inclusive.  If a kill statement is needed also to force delete folders and there content that would help.  Please advise of the best method to automate this and any help would be appreciated.  Thank you.
ASKED: May 6, 2011  12:40 AM
UPDATED: June 3, 2011  1:03 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

just bash in the code for delete into command line or VBS etc.. with it pointed to the directory such as C:\folders with crap\* where the * in windows is the wildcard for anything in this location.

Job done.

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following