How to find a hidden icon in system tray using FindWindowEx or a similar function?
Question
Is it possible to find a window by class using FindWindowsEx if it's currently hidden in the system tray? Looking for children of ToolbarWindow32
works if the icon is not hidden, but what to do when it is?
Thanks.
Solution
Tray icons are not windows, you cannot find them with FindWindowsEx. You might find them with TB_GETBUTTON. The buck stops at trying to find hidden icons, they are just not there. Revealing hidden icons is implemented differently in different versions of Windows, but they are dynamically created when you reveal them. There is no API to enumerate them.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow