Thursday, 14 July 2011

How do I... Force Disk Cleanup to delete all temporary fi les?

If you’ve ever run the Microsoft Windows XP’s Disk Cleanup utility, you probably discovered
that your temporary fi les occupy a signifi cant amount of space. You might select the
Temporary Files check box in order to allow the Disk Cleanup utility to delete the fi les in
the Temp folder, but the Disk Cleanup utility will not remove all the fi les. The reason for this
oddity is that the confi guration for the Disk Cleanup utility does not allow deletion of fi les
accessed in the last seven days.
Alter the parametersBy altering the LastAccess value in the registry, you can confi gure the Disk
Cleanup utility to delete all the fi les in the Temp folder regardless of the last accessed date. Here’s
how:
1. Launch the Registry Editor (Regedit.exe).
2. Go to
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\
Explorer\VolumeCaches\Temporary Files
3. Locate and double-click the LastAccess value.
4. When you see the Edit DWORD Value dialog box, change the Value Data setting from 7 to 0
and click OK.
5. To complete the operation, close the Registry Editor and restart Windows XP.
Changing the value to 0 will force the Disk Cleanup utility to delete all the fi les in the Temp
folder every time you select the Temporary Files check box.
Notes: Since editing the registry is risky, be sure you have a verifi ed backup before saving any
changes. This tip applies to both Windows XP Home and Windows XP Professional.

No comments:

Post a Comment