private void SetCurrentItemInEditMode(bool EditMode)
{
if (product_tree.SelectedItem is TreeViewItem)
{
TreeViewItem tvi = product_tree.SelectedItem as TreeViewItem;
// Also make sure that the TreeViewItem
// uses an EditableTextBlock as its header
if (tvi.Header is EditableTextBlock)
{
EditableTextBlock etb = tvi.Header as EditableTextBlock;
// Finally make sure that we are
// allowed to edit the TextBlock
if (etb.IsEditable)
etb.IsInEditMode = EditMode;
}
}
}
error: The type or namespace name 'EditableTextBlock' could not be found (are you missing a using directive or an assembly reference?)
i'm making a TreeView in WPF application. TreeViewItem is fetched from database and i want to make editable treeviewitem when i do double click on TreeViewItem. but i'm getting this error. i searched about this error but couldn't find any good solution