Manually Remove all temporary file in one click

0
231
We all know what is temp files in windows but for those who don’t know what is temporary files in windows
here is the brief info.Windows temporary files are usually left over from previous installation or documents once needed by windows to run certain task.These files can grow large if we don’t remove them in short time period.
For example if we don’t remove temporary files within 10-20 days it will grow round about 400MB – 500MB.
It is based on your time of using Pc/laptop.
So, keep habit of removing temporary files in short period of time.
Here is the trick to remove temporary file using some lines of code.
First of all create one text file then copy/paste following code.

Batch Code


del /q /s "c:\winnt\temp\*.*"
del /q /s "c:\windows\temp\*.*"
del /q /s "%USERPROFILE%\Local Settings\Temp\*.*"
del /q /s "%USERPROFILE%\Local Settings\Temporary Internet Files\*.*"
del /q /s "%USERPROFILE%\Cookies\*.*"
Rmdir /q /s "c:\winnt\Temp"
Rmdir /q /s "c:\windows\Temp"
Rmdir /q /s "%USERPROFILE%\Local Settings\Temp"
Rmdir /q /s "%USERPROFILE%\Local Settings\Temporary Internet Files"
Rmdir /q /s "%USERPROFILE%\Cookies\*.*"
md "c:\winnt\Temp"
md "c:\windows\temp"
md "%USERPROFILE%\Local Settings\Temp"
md "%USERPROFILE%\Local Settings\Temporary Internet Files"
md "%USERPROFILE%\Cookies"

Now save this file as a .bat extension.
That’s it.
Now whenever you want to delete temporary files just run above file.
Explanation:
In code first five lines remove all file from particular folder.
Second five lines remove particular directory.
Last five lines create directories that were earlier removed.
If you have any problem then comment here.

LEAVE A REPLY

Please enter your comment!
Please enter your name here