Have two Windows, the login window and the main window, after login according to the main window; In the main window right-click pop-up menu, and then the main window for other reasons to return to the login window, but the menu is still exist; The DestroyMenu there is no effect; The popup menu is TrackPopupMenu ;
CodePudding user response:
Try call before TrackPopupMenu SetForegroundWindow