[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

9.0

Deleting SubDirectories and their contents in a BAT file

Asked by Kayg_Hunter in MS DOS, Windows XP Operating System

Tags: DOS, BAT, MS-Dos

Basically, I need to create a BAT file to run at startup that will clean Temp Files, Temp Internet Files, Cookies, Prefetch, Recent Docs etc (all are listed in the code snippet)

I have tested the file in the code below and for the most part it works, however it does not delete any Sub Directories and I cannot figure out how to make it do so. I am not used to writing overly advanced BAT files and don't understand a lot of the %%d type things to be honest.

I have tried using Cleanmgr /sagerun:n and that at startup but I find it doesn't empty the bin, doesn't clear temp files or temp internet files.

I cannot use AD and GPO as I am not an admin, I could get them to allow me the access but would love to solve this with a BAT file as there a lot more problems like this on the network here that would be a bonus to me to fix (not cash bonus sry, can't share that with ye lol)

So basically, I need the BAT file to delete the subdirectories created by XP under \Local Settings\Temporary Internet Files\Content.IE5 along with the files.

I know I can use IF EXIST to check for directories but that doesn't accept wildcards, so how I do go about it? And optionall, to give an output to a TXT file on C:\ would be great, not really needed though tbh.

Am assigning 250 points to this as I would love to get it resolved asap, before my Instructor gets back would be awesome.
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
echo Y|del  "C:\Documents and Settings\User1\Cookies\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User1\Local Settings\Temp\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User1\Local Settings\Temporary Internet Files\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User1\Local Settings\History\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User1\Recent\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User2\Cookies\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User2\Local Settings\History\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User2\Local Settings\Temp\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User2\Local Settings\Temporary Internet Files\*.*" /s
 
echo Y|del  "C:\Documents and Settings\User2\Recent\*.*" /s
 
echo Y|del  "C:\WINDOWS\Temp\*.*" /s
 
echo Y|del  "C:\WINDOWS\Prefetch\*.*" /s
 
echo Y|del  "C:\RECYCLER\S-1-5-21-3087080065-4144176109-1312135163-1003\*.*" /s
[+][-]08/17/09 06:59 AM, ID: 25114487Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zones: MS DOS, Windows XP Operating System
Tags: DOS, BAT, MS-Dos
Sign Up Now!
Solution Provided By: t0t0
Participating Experts: 3
Solution Grade: A
 
[+][-]08/17/09 06:45 AM, ID: 25114312Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/17/09 06:48 AM, ID: 25114350Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/17/09 06:49 AM, ID: 25114367Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/17/09 06:56 AM, ID: 25114461Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/17/09 06:58 AM, ID: 25114474Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/17/09 07:00 AM, ID: 25114500Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/17/09 07:05 AM, ID: 25114550Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/17/09 07:07 AM, ID: 25114568Assisted Solution

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 30-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]08/17/09 07:11 AM, ID: 25114585Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/17/09 07:15 AM, ID: 25114626Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/17/09 07:25 AM, ID: 25114701Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/17/09 04:32 PM, ID: 25119245Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-92 - Hierarchy / EE_QW_3_20080625