Completed
Last Updated: 23 May 2019 13:20 by ADMIN
Release R2 2019 SP1 (LIB 2019.2.527)

Afternoon

 

We have a RadTReeView that we drag nodes around to reorder within the same treeview.

There are about 2000 nodes in the tree that is a self referencing data bound and goes about 15 levels deep at some parts of the tree

When we click left mouse down (keeping it down) to drag and drop reorder a node, using the mouse wheel to scroll the tree up or down does not work anymore

We want to for instance drag a node from a location to another location outside the current view, using the mouse wheel to navigate the tree view up and down. This used to work, but not after upgrading to the new 2019 telerik.

Is there a tree view control option that needs to be toggled for this to work?

Thank you

Theo

Completed
Last Updated: 02 Jul 2019 08:04 by ADMIN
Release R3 2019 (LIB 2019.2.708)
Created by: avani
Comments: 2
Category: TreeView
Type: Feature Request
1

Hi all,

 

RadTreeView is very nice control , For treeline we can give line style, color but we can't set line thickness,

I want to change thickness of Treeline can you guide me how to do it?

Completed
Last Updated: 20 Feb 2014 15:27 by ADMIN
Workaround:
Instead of {RadTreeNode}.Nodes.Clear(), use 

 while ({RadTreeNode}.Nodes.Count>0)
          {
              {RadTreeNode}.Nodes.RemoveAt(0);
          }
Declined
Last Updated: 16 Feb 2024 19:49 by ADMIN
Created by: avani
Comments: 2
Category: TreeView
Type: Bug Report
1

Hi All,

 

I have made User control for custom node, in this user control i have used following controls

1 RadLabel (no of control - 3)

2 RadPanel (no of control -1)

3 PictureBox (no of Control - 4 )

4 TableLayoutPanel (no of control -3)

Means i have used total 11 controls within my user control.

Height of usercontrol = 146

Width of Usercontrol = 595

 

I have taken RadTreeView and above UserControl added as Node,following properties of treeview is set

this.radTreeView1.DataSource = Staff.GetStaff();
            this.radTreeView1.ParentMember = "ParentID";
            this.radTreeView1.ChildMember = "ID";
            this.radTreeView1.DisplayMember = "Department";
            this.radTreeView1.CreateNodeElement += this.OnCreateNodeElement;

this.radTreeView1.TreeViewElement.AutoSizeItems = true;
            this.radTreeView1.ShowRootLines = false;
            this.radTreeView1.FullRowSelect = false;
            this.radTreeView1.ShowLines = true;
            this.radTreeView1.LineStyle = TreeLineStyle.Solid;
            this.radTreeView1.LineColor = Color.FromArgb(110, 153, 210);
            this.radTreeView1.TreeIndent = 50;

this.radTreeView1.ExpandAll();

 

But when i run the code it shows like this means my control is not displaying and the property "AutoSizeItems" is not working.

 

hope for quick reply

Completed
Last Updated: 23 Sep 2022 13:07 by ADMIN
Release R3 2022

Please run the attached sample project and follow the steps illustrated in the gif file. You will notice the following behavior:

If you select multiple items/nodes and then right click on the last selected item/node, the context menu comes up as expected and multiple selection is kept. But if you right click on any other item/node that is selected,the selected nodes become unselected and only the node you are over becomes selected. 

The multiple selection is kept in Windows Explorer and VS Solution explorer wne you right click over an already selected node.

Workaround:

        public RadForm1()
        {
            InitializeComponent();

            this.radTreeView1.MultiSelect = true;
            this.radTreeView1.AllowDefaultContextMenu = true; 
        } 

        class CustomTreeViewElement : RadTreeViewElement
        { 
            protected override Type ThemeEffectiveType
            {
                get
                {
                    return typeof(RadTreeViewElement);
                }
            }

            protected override bool ProcessMouseDown(MouseEventArgs e)
            {
                if (e.Button == MouseButtons.Right)
                {
                    RadContextMenu menu = this.ContextMenu; 
                    RadTreeNode node = this.GetNodeAt(e.Location);
                    if (node!=null)
                    {
                        node.Selected = true;
                    }
                    if (node != null && node.ContextMenu != null)
                    { 
                        menu = node.ContextMenu;
                    } 
                    if (menu == null && this.AllowDefaultContextMenu)
                    {
                        menu = this.InitializeDefaultContextMenu(node);
                    } 
                    if (menu != null)
                    { 
                        RadControl parentControl = (this.ElementTree.Control as RadControl);

                        if (parentControl != null)
                        {
                            menu.ThemeName = parentControl.ThemeName;
                            menu.DropDown.RightToLeft = parentControl.RightToLeft;
                        }

                        TreeViewContextMenuOpeningEventArgs args = new TreeViewContextMenuOpeningEventArgs(node, menu, this);
                        OnContextMenuOpening(args);

                        if (!args.Cancel)
                        {
                            menu.Show(this.ElementTree.Control, e.Location);
                            return true;
                        };
                    }
                }
                return base.ProcessMouseDown(e);
            } 
        }

        class CustomTreeView : RadTreeView
        {  
            protected override RadTreeViewElement CreateTreeViewElement()
            {
                return new CustomTreeViewElement();
            }
           
            public override string ThemeClassName
            {
                get
                {
                    return typeof(RadTreeView).FullName;
                }
            }

            protected override void WndProc(ref Message m)
            {
                switch (m.Msg)
                {
                    case 0x7b:
                         
                        return;
                }

                base.WndProc(ref m);
            }
        }

Completed
Last Updated: 15 Dec 2020 09:27 by ADMIN
Release R1 2021 (LIB 2020.3.1215)

Hi,

  on the Winform Demo application, go to the TreeView demos, and selection "Selection".
1) select the "Folders" item listed under the "Inbox" item.

2) Collapse the "Inbox" item by clicking the ARROW next to the "Inbox"

3) Hold down the SHIFT key and left-mouse click on the "Outbox" item, you end up with a selection all the way up the tree to the ROOT element

Unplanned
Last Updated: 15 Aug 2017 09:33 by Svetlin
Sort the selected nodes according to their position in the tree
Completed
Last Updated: 10 Jun 2021 13:34 by ADMIN
Release R2 2021 SP1

Please refer to the attached sample project and try to edit a node. In random situations the Node argument in the Edited event is null or points to a wrong data node:

Completed
Last Updated: 27 Aug 2021 10:27 by ADMIN
Release R3 2021

1. Start WinAppDriver.exe

2. Open the attached sample solution

3. Click "Run all" tests 

You will see that the test will not be able to locate any RadTreeNode elements located outside of the first parent node collection. Note that the test uses "FindElementByName("name")" method. 

Completed
Last Updated: 17 Aug 2012 03:27 by ADMIN
1. Place a RadTreeView in a form and add enough items to show scrollbars;
2. Show the form using ShowDialog() and close it
3. Open it again and note that there are no scrollbars in the RadTreeView
Completed
Last Updated: 28 Dec 2012 03:01 by ADMIN
The following code produces an error when the user attempts to edit the root node:
DataTable dt = new DataTable();
DataColumn column = new DataColumn("ID", typeof(int));
column.AllowDBNull = false;
column.AutoIncrement = true;
dt.Columns.Add(column);
dt.Columns.Add(new DataColumn("ParentID", typeof(int)));
dt.Columns.Add(new DataColumn("Name", typeof(string)));
dt.Columns.Add(new DataColumn("Note", typeof(string)));
dt.Rows.Add(1, DBNull.Value, "Root", "Note1");
dt.Rows.Add(2, 1, "First", "Note1");
dt.Rows.Add(3, 1, "Second", "Note1");
dt.Rows.Add(4, 3, "Third", "Note1");
this.radTreeView1.DisplayMember = "Name";
this.radTreeView1.ParentMember = "ParentID";
this.radTreeView1.ChildMember = "ID";
this.radTreeView1.ValueMember = "ID";
this.radTreeView1.DataSource = dt;
radTreeView1.TreeViewElement.EditMode = TreeNodeEditMode.Text;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using Telerik.WinControls.UI;
namespace Lab.Tree
{
public partial class TreeSelfreferenceEditRootNodeForm : Form
{
private RadTreeView treeView = new RadTreeView();
private BindingSource bindingSource = new BindingSource();
public TreeSelfreferenceEditRootNodeForm()
{
InitializeComponent();
treeView.Dock = DockStyle.Fill;
treeView.Parent = this;
treeView.AllowEdit = true;
DataTable dt = new DataTable();
DataColumn column = new DataColumn("ID", typeof(int));
column.AllowDBNull = false;
column.AutoIncrement = true;
dt.Columns.Add(column);
dt.Columns.Add(new DataColumn("ParentID", typeof(int)));
dt.Columns.Add(new DataColumn("Name", typeof(string)));
dt.Columns.Add(new DataColumn("Note", typeof(string)));
dt.Rows.Add(1, DBNull.Value, "Root", "Note1");
dt.Rows.Add(2, 1, "First", "Note1");
dt.Rows.Add(3, 1, "Second", "Note1");
dt.Rows.Add(4, 3, "Third", "Note1");
bindingSource.DataSource = dt;
treeView.DisplayMember = "Name";
treeView.ParentMember = "ParentID";
treeView.ChildMember = "ID";
treeView.ValueMember = "ID";
treeView.DataSource = bindingSource;
treeView.TreeViewElement.EditMode = TreeNodeEditMode.Text;
}
}
}
Completed
Last Updated: 31 Aug 2011 04:49 by ADMIN
SelectedNodeChanged event not owrk properly during remove operation of SelectedNode
Completed
Last Updated: 03 Jun 2022 08:38 by ADMIN
Release R2 2022 SP1
Created by: Humberto
Comments: 0
Category: TreeView
Type: Bug Report
1
When the RadTreeView.EnableRadAccessibilityObjects property is set to true and the Narrator is turned on, it doesn't read the expanded/collapsed state of the selected node. It would be good to have this functionality. 
Completed
Last Updated: 15 Sep 2011 06:58 by ADMIN
ADMIN
Created by: Julian Benkov
Comments: 0
Category: TreeView
Type: Bug Report
1
When i have the root nodes loaded, but there are more nodes than fit in the visible area of the treeview, the scrollbar is not automatically shown. I've tried setting the AutoScroll option to true, but that doesn't help.
Unplanned
Last Updated: 27 Feb 2024 13:19 by ADMIN

Repro-steps:

  1. Create a RadTreeView
  2. Set the TreeViewElement.ExpandTimerInterval to 5 seconds.
  3. Enable drag/drop.
  4. Fill the tree with random nodes and childnodes
  5. Drag a node over other nodes. Make sure you do not hover longer than 5 seconds over a single node. So just move around.

Observed behavior:

  1. After 5 seconds the node you are just hovering over, is expanding.

Expected behavior:

  1. No node will automatically expand. Every time a new node is hovered over, the timer will reset.


Unplanned
Last Updated: 30 Aug 2022 06:04 by Massimo

Steps to reproduce the issue:

1. Run the example app.
2. Click undo (the last item is removed).
3. Click redo (the last item should be added to the Treeview, it does not)
If I run the application and click undo twice and then redo twice, the things work. The Treeview is not updated if I add and remove the same element instance to the binding list.

Workaround: rebind the treeview after redo or create a new instance of the Element class with the same name and id.

Completed
Last Updated: 27 Mar 2013 02:44 by ADMIN
NullReferenceException in the UpdateLines method somehow triggered by the OnProcessMouseUp handler, when I'm trying to perform a drag and drop move in my treeview, that is fully managed by an inner model. The DnD events are bound and trigger delete + add actions in the tree.
Declined
Last Updated: 12 Jun 2018 08:14 by ADMIN
To reproduce: add some nodes to the tree view at design time

        public RadForm1()
        {
            InitializeComponent();

            this.radTreeView1.AllowDragDrop = true;
            this.radTreeView1.DragEnding += radTreeView1_DragEnding;
        }
        
        private void radTreeView1_DragEnding(object sender, Telerik.WinControls.UI.RadTreeViewDragCancelEventArgs e)
        {
            if (MessageBox.Show("Are you sure you want to move?", "Question", MessageBoxButtons.YesNo) == System.Windows.Forms.DialogResult.No)
            {
                e.Cancel = true;
            }
        }

Then try to drag and drop a node. You will notice that the application hangs

Workaround: use RadMessageBox
Completed
Last Updated: 28 Dec 2012 07:39 by ADMIN
bind the tree and try to add a node to the control - error occurs
Completed
Last Updated: 18 Sep 2012 09:16 by ADMIN
To reproduce:
public Form1()
        {
            InitializeComponent();

            DataTable table = new DataTable();
            table.Columns.Add("ID");
            table.Columns.Add("Name");

            for (int i = 0; i < 10; i++)
            {