Problem with OnToolbarDropDown
-
Hello, i need to realize a dropdown-button within a toolbar by using mfc70. I added the extended style TBSTYLE_EX_DRAWDARROWS to the toolbar and also i modified the style of the corresponding button (TBSTYLE_DROPDOWN). Clicking on the arrow will call the message-handler i defined in the following way : afx_msg void OnToolbarDropDown(NMHDR* pnmh, LRESULT* plRes); The message-map-entry is the following : ON_NOTIFY(TBN_DROPDOWN, AFX_IDW_TOOLBAR, OnToolbarDropDown) In the msdn-description the NMHDR-structure is defined as typedef struct tagNMHDR { HWND hwndFrom; UINT idFrom; UINT code; } NMHDR; I thought that i could read the idFrom-value to determine the resource-ID of the button where the arrow was clicked. But for different dropdown-buttons the value is always the same and it matches to no button-ID available! So how can i determine the id of the corresponding dropdown-button by using the NMHDR-structure instead of the NMTOOLBAR-structure (used in vc60)? Best regards tabor25