Files
windows-scripts/RebuildThumbnailCache.bat
2023-03-05 21:08:50 -06:00

30 lines
654 B
Batchfile

@echo off
set thumbcache=%localappdata%\thumbCache.db
echo The Explorer process must be killed to delete the Thumbnail DB.
echo.
echo Please SAVE ALL OPEN WORK before continuing.
echo.
pause
echo.
If exist "%thumbcache%" goto delID
echo.
echo Thumbnail DB has already been deleted.
echo.
pause
exit /B
:delID
echo Attempting to delete Thumbnail DB...
echo.
ie4uinit.exe -ClearthumbCache
taskkill /IM explorer.exe /F
del "%thumbcache%" /A
del "%localappdata%\Microsoft\Windows\Explorer\thumbcache*" /A
echo.
echo thumb DB has been successfully deleted. Please "restart your PC" now to rebuild your thumb cache.
echo.
start explorer.exe
pause
exit /B