Sunday, June 28, 2009

make a Windows XP Disk Cleanup Tool

These instructions will show you how to create an unattended disk cleanup which will also empty your prefetch folder providing Windows XP is installed in c:\windows.

1. Create a new text file and place the following contents inside:
c:\windows\system32\cleanmgr.exe /dc /sageset: 1
c:
cd \
cd c:\windows\prefetch
del *.* /q

2. Save the file, changing the extension from .txt to .bat
Now name it diskclean.bat

3. Execute the file. This will run the Disk Cleanup program in a special mode which asks what items you will want cleaned when Disk Cleanup performs an unattended cleanup. Check the items you wish to have cleaned up, then click OK.

4. Right-click on the diskclean.bat file and click edit. Change the first line to read:

c:\windows\system32\cleanmgr.exe /dc /sagerun: 1

5. Save the file. You can execute this file in place of running Disk Cleanup, or, to have this program run unattended, run the Add Scheduled Task Wizard in the Control Panel and create a scheduled task using the clean.bat file you just created.

To download one already made click HERE.
Save to your Desktop and then follow the instructions at #3.

0 comments:

Post a Comment | Feed

Post a Comment

Please leave your comment



 

TechRavi

Total Pageviews

Followers

Techtricx Copyright © 2009