Using LoadImage
I changed the icon of all the windows in a group. However the group icon does not change. How can I get the corresponding group to a window and set
Your issue is this: The icon does infact take the icon of the first WINDOW, not exe. HOWEVER, after setting the icons, you have to right click on the icon in the taskbar, then pin it, then unpin it. On unpin the taskbar icon now takes the first windows icon.
I don't know how to programatically do this to maybe @RemyLebeau knows. Maybe setClassLongPtr
? Not sure.
Now when it's pinned you want to make it use the same icon, so set the registry value like @RemyLebeau suggested.
Also I don't know how to explain this, but after unpinning, and the icon takes, if you open the jump list, the icon reverts back to the exe's icon. This may be fixed with the registry setting for pinned icon, I'm not sure.
Wow so Win7 taskbar is so tweakish.
Edit: I tried setting my registry values and the icon didnt work. It might have to do something with: the registry entires that i found for TaskbarGroupIcon
all had a data value ending with a comma and a number (ex: ,-4
in %SystemRoot%\System32\imageres.dll,-4
)