How To Delete A Temporary Folder

Table of contents:

How To Delete A Temporary Folder
How To Delete A Temporary Folder

Video: How To Delete A Temporary Folder

Video: How To Delete A Temporary Folder
Video: How to Cleanup Your Computer - Fully Delete Temporary Files and Free Disk Space 2024, November
Anonim

Most programs create temporary files as they run. After completing its work, each program must remove them. However, in some cases (incorrect stopping of the program, errors in the application) temporary files are not automatically deleted.

How to delete a temporary folder
How to delete a temporary folder

Instructions

Step 1

Click the "Start" button to bring up the main menu of the system and go to "Run" (for Windows XP) or "All Programs" (for Windows Vista and Windows 7).

Step 2

Expand the "Accessories" link and go to "Run" (for Windows Vista and Windows 7).

Step 3

Enter% TEMP% in the Open field to search for a temporary folder.

Step 4

Click OK to confirm the command.

Step 5

Press the Ctrl + A keys at the same time to select all files in the opened folder.

Step 6

Press the Del key to execute the operation of deleting the selected files and confirm the execution of the command by pressing the "Yes" button.

Step 7

Return to the main menu "Start" and go to the item "Control Panel" to create a single folder for storing temporary files of the system.

Step 8

Select "System" and go to "Advanced system settings".

Step 9

Expand the Environment Variables link, select the TEMP variable and click the Modify button.

Step 10

Enter C: / Windows / Temp in the Variable Value field and click OK to apply the selected changes.

Step 11

Open Notepad and copy the following code:

pushd% TEMP% && rd / s / q. > nul 2> & 1

pushd% WinDir% / TEMP && rd / s / q. > nul 2> & 1.

Step 12

Save the created file with any name, but with the extension.cmd.

Step 13

Return to the main Start menu and go to Run to launch the Group Policy Editor.

Step 14

Enter gpedit.msc in the Open field and click OK.

Step 15

Expand the Computer Configuration link and go to Windows Configuration.

Step 16

Go to Scripts (Startup / Shutdown) and expand the Shutdown link on the right side of the application window.

Step 17

Click the Add button in the Add Script dialog box and specify the path to the generated.cmd file.

Step 18

Click OK, then Apply and OK again to apply the selected changes.

Step 19

Repeat the above procedure in the User Configuration section.

Recommended: