You need to show the code that creates the taskbar icon. Are you intercepting WM_RBUTTONDOWN or WM_CONTEXTMENU to display the popup menu?