CTreeCtrl::GetDropHilightItem

HTREEITEM GetDropHilightItem( );

Return Value

The handle of the item dropped if successful; otherwise NULL.

Remarks

Call this function to retrieve the item that is the target of a drag-and-drop operation.

Example

// The pointer to my tree control.
extern CTreeCtrl* pmyTreeCtrl;
// The point to test.
extern CPoint myPoint;

// Set the item at the point myPoint as the drop target.
UINT uFlags;
HTREEITEM hItem = pmyTreeCtrl->HitTest(myPoint, &uFlags);

if ((hItem != NULL) && (TVHT_ONITEM & uFlags))
{
   pmyTreeCtrl->SelectDropTarget(hItem);
   ASSERT(pmyTreeCtrl->GetDropHilightItem() == hItem);
}

CTreeCtrl OverviewClass MembersHierarchy Chart

See Also   CTreeCtrl::SelectDropTarget