How WinXP automatically cleans up Temp folder

  
        Perhaps many computer novices are not aware of the role of the Temp folder in WinXP. In fact, its main function is to temporarily generate some cache files in the storage system. Over time, more and more files in the Temp folder, then the system will become more and more Card, the following Windows Home Xiaobian teaches you how to automatically clean up the Temp folder.
1. Create D:\\UserData\\TEMP directory on the D drive
2. Right click on "My Computer", "Properties", "Advanced", open the "Environment Variables" dialog box, and set the user variables and system. The variables are changed to D:\\UserData\\TEMP.
3, create a new text document, write two lines of code inside:
RD %TEMP% /S/Q
MKDIR %TEMP%
Then save as *.bat format (such as CleanTEMP. Bat), so just open the CleanTEMP.bat file and automatically empty the mess under the Temp folder.
4, after the above three steps, we can actually clear those temporary files, but can not be satisfied with this, our goal is to let Windows automatically empty, free our hands:
Open Group Policy (run Gpedit.msc), open "Computer Configuration - Windows Settings - Script (Start /Shutdown)", and then open "Start" or "Shutdown", the effect is the same, one is to empty Temp when logging in, one is empty when shutting down, here I Select "Shutdown". Click "Add" to import the *.bat file you just made, click "OK" and everything will be done.
The above is about how WinXP automatically cleans up the entire contents of the Temp folder. Windows Home Xiaobian thinks that many users' computers will be specially used after a period of use. In fact, many junk files are not cleaned up in time, so over time. This will cause the computer to run faster than the card.

Copyright © Windows knowledge All Rights Reserved