Temp command in run

broken image

This is located in C:\Documents and Settings\username\Local Settings\Temp. Suppose you view a pdf file online in the browser, then the file is actually stored in this temp folder. There is another temp folder where temporary files are kept. So deletion of temp files can also be done using this environment variable del %TEMP%\* forfiles /P %TEMP%\* /C 'cmd /c if rmdir /S /Q XP rmdir /s /q '%userprofile%\Local Settings\Temporary Internet Files' del %userprofile%\AppData\Local\Temp\* forfiles /P %userprofile%\AppData\Local\Temp\ /C 'cmd /c if rmdir /S /Q can also verify that the environment variables TEMP or TMP points to this folder. This cache can be deleted with the below commands. On Windows 7 there’s another folder AppData\Local\Temp which keeps temporary files created by various applications run on the system. Delete the subfolders in ‘Temporary Internet Files’įorfiles /P '%userprofile%\AppData\Local\Temporary Internet Files\*' /C 'cmd /c if rmdir /S /Q of removing the whole directory, we use the above two commands to delete only the files and subfolders and keep the root folder untouched.To delete the files from command line, we need to run couple of commands.ĭel '%userprofile%\AppData\Local\Temporary Internet Files\*' Once done, you can open the folder in explorer and delete the files.

broken image

Refer Take ownership of file for detailed information on this command. Takeown /R /F '%userprofile%\AppData\Local\Temporary Internet Files'