-
Notifications
You must be signed in to change notification settings - Fork 0
/
Fix blank icons.cmd
38 lines (34 loc) · 1.01 KB
/
Fix blank icons.cmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
@echo off
set iconcache=%localappdata%\IconCache.db
set iconcache_x=%localappdata%\Microsoft\Windows\Explorer\iconcache*
echo.
echo The explorer process must be temporarily killed before deleting the IconCache.db file.
echo Please SAVE ALL OPEN WORK before continuing.
echo.
pause
echo.
If exist "%iconcache%" goto delete
echo The %localappdata%\IconCache.db file has already been deleted.
echo.
If exist "%iconcache_x%" goto delete
echo The %localappdata%\Microsoft\Windows\Explorer\IconCache_*.db files have already been deleted.
echo.
exit /B
:delete
echo Attempting to delete IconCache.db files...
echo.
ie4uinit.exe -show
taskkill /IM explorer.exe /F
If exist del /A /F /Q "%iconcache%"
If exist del /A /F /Q "%iconcache_x%"
start explorer.exe
echo IconCache database files have been successfully deleted.
echo.
echo You will need to restart the PC to finish rebuilding your icon cache.
CHOICE /C:YN /M "Do you want to restart the PC now?"
IF ERRORLEVEL 2 goto no
IF ERRORLEVEL 1 goto yes
:yes
shutdown /r /f /t 00
:no
exit