CTreeCtrl::EditLabel
Call this function to begin in-place editing of the specified item's text.
CEdit* EditLabel(
HTREEITEM hItem
);
Параметры
- hItem
Handle of the tree item to be edited.
Возвращаемое значение
If successful, a pointer to the CEdit object that is used to edit the item text; otherwise NULL.
Заметки
The editing is accomplished by replacing the text of the item with a single-line edit control containing the text.
Пример
// Make sure the focus is set to the tree control.
m_TreeCtrl.SetFocus();
// Show the edit control on the label of the selected item.
// The tree control must have the TVS_EDITLABELS style set.
HTREEITEM hSel = m_TreeCtrl.GetSelectedItem();
CEdit* pmyEdit = m_TreeCtrl.EditLabel(hSel);
ASSERT(pmyEdit != NULL);
Требования
Header: afxcmn.h