Original post : Delete Temporary Files and Folders: Guide for Windows XP, Vista, 7, 8, 8.1, 10.
Do not delete any temporary files and folders if you've recently installed a new software or update, but didn't perform a restart of your computer. Certain software can still use the Temp folder until you restart the PC.
%temp%
The Temp folder holds all the temporary files and folders for the Windows XP systems.
C:\
del /q/f/s %TEMP%\*
If you installed a new update or software, restart the computer before you delete the Temp folder. Certain software can still use the Temp folder.
disk cleanup
Make sure you perform a restart of your computer before you delete the contents of the Temp folder. Certain software or updates can still use the Temp folder if you haven't performed a restart.
The Temp folder holds all temporary files and folders on your computer.