NiceButDim
Programmer
Hi,
I've created a menu for a CTreeCtrl object that pops-up when the user right clicks. When you do the click, the item under the mouse is highlighted although not selected (i.e. *CTreeCtrl->GetSelectedItem doesn't return it). I would like to manually set the currently selected item to be the item under the mouse at the point of right clicking but I don't know how.
I assumed that the info would be held in the NMHDR structure passed to the right click function, but it doesn't appear to be.
Any help would be appeciated.
I've created a menu for a CTreeCtrl object that pops-up when the user right clicks. When you do the click, the item under the mouse is highlighted although not selected (i.e. *CTreeCtrl->GetSelectedItem doesn't return it). I would like to manually set the currently selected item to be the item under the mouse at the point of right clicking but I don't know how.
I assumed that the info would be held in the NMHDR structure passed to the right click function, but it doesn't appear to be.
Any help would be appeciated.