Modify the Windows 7 taskbar pinned program icons

Purpose: Clear or create your own pinned program icons in the Windows taskbar

In a case where you need to alter the windows taskbar, you will come to notice that there is actually no clean way to script the Windows Taskbar. This operating system object is meant to be edited by the user only with no API for programs or scripts to alter it. Hence taskbar customization is instantly an OS tweak. I recommend caution and deeper understanding of Windows 7 OS.

Clear user of all taskbar icons

The user must logoff and login back for the changes to apply. Alternatively the system must be restarted.

1
2
3
4
5
REM Create a backup of the registry key you are about to modify
REG COPY "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband_BACKUP" /f
 
REM Clear the registry key of all values, which empties the taskbar
REG ADD "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" /v "Favorites" /t "REG_BINARY" /d "" /f
REM Create a backup of the registry key you are about to modify
REG COPY "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband_BACKUP" /f

REM Clear the registry key of all values, which empties the taskbar
REG ADD "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" /v "Favorites" /t "REG_BINARY" /d "" /f
Add icons of your choice

The data in this registry key is in a pretty raw format (you can go see for yourself). You can only distribute the pinned icons by first clearing the taskbar in your test computer (make sure that the OS and the BITS of the OS are going to be the same in the test computer and in the target computer(s)). Secondly pin only the icons that you want to distribute and make sure that all of the programs are installed in the same way (programs are installed in the same location) in the target computer(s) than in your test computer. Now copy the raw value from the registry and distribute it accordingly.

1
2
3
4
5
REM Create a backup of the registry key you are about to modify
REG COPY "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband_BACKUP" /f
 
REM Distribute your own registry data
REG ADD "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" /v "Favorites" /t "REG_BINARY" /d "COPY VALUE HERE" /f
REM Create a backup of the registry key you are about to modify
REG COPY "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband_BACKUP" /f

REM Distribute your own registry data
REG ADD "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Taskband" /v "Favorites" /t "REG_BINARY" /d "COPY VALUE HERE" /f

Leave a Reply

Your email address will not be published. Required fields are marked *


nine − four =

Post Navigation