CTreeCtrl::SelectItem
Call this function to select the given tree view item.
BOOL SelectItem(
HTREEITEM hItem
);
Параметры
- hItem
Handle of a tree item.
Возвращаемое значение
Nonzero if successful; otherwise 0.
Заметки
If hItem is NULL, then this function selects no item.
Пример
// Select the item that is at the point myPoint.
UINT uFlags;
HTREEITEM hItem = m_TreeCtrl.HitTest(myPoint, &uFlags);
if ((hItem != NULL) && (TVHT_ONITEM & uFlags))
{
m_TreeCtrl.SelectItem(hItem);
}
Требования
Header: afxcmn.h