Drag and drop from kendo treeview to a div container

2 posts, 0 answers
  1. German
    German avatar
    1 posts
    Member since:
    Jan 2013

    Posted 14 Jan 2013 Link to this post


    I'm currently doing it this way:

                KendoTreeView treeView = myManager.ActiveBrowser.Find.ByXPath<KendoTreeView>("//div[@data-role='treeview']");

                IList<KendoTreeNode> listNodes = treeView.AllNodes;

                int elem = 1;




                listNodes.ElementAt(elem).DragTo(new Point(500, 720));

    But it's not working correctly. The mouse starts from the center of the treeview, and all elements whose text does not have the length of at least half the horizontal size of the treeview, are not being selected. Is there a better way to do it?
  2. Plamen
    Plamen avatar
    8 posts

    Posted 18 Jan 2013 Link to this post

    Hello German,

    I apologize for the delay in getting back to you.

    To overcome the problem you can perform Drag&Drop against the child Span element contained in the KendoTreeNode(see screenshot). Please try one of the following lines of code and let me know if you need further assistance on this.
    listNodes[elem].Find.AllByTagName<HtmlSpan>("span")[0].DragTo(new Point(720, 520));


    listNodes.ElementAt(elem).Find.AllByTagName<HtmlSpan>("span")[0].DragTo(new Point(720, 520));

    the Telerik team
    Quickly become an expert in Test Studio, check out our new training sessions!
    Test Studio Trainings
Back to Top