Select selected node

3 posts, 1 answers
  1. BigzampanoXXl
    BigzampanoXXl avatar
    60 posts
    Member since:
    Jan 2007

    Posted 11 Jan 2013 Link to this post

    Hello,

    is it possible to "select" the node which is currently selected? Right now the select-event doesn't trigger if the node is already selected. I need it to be triggered each time the user clicks on a node.

    Thanks!
  2. Answer
    Alex Gyoshev
    Admin
    Alex Gyoshev avatar
    2500 posts

    Posted 14 Jan 2013 Link to this post

    Hello Dietmar,

    You can bind a filtered event handler which triggers a select event.

        var treeview = $("#treeview").data("kendoTreeView");
        treeview.wrapper.on("click", ".k-state-selected", function(e) {
            treeview.trigger("select", {
                node: $(e.target).closest(".k-item")[0]
            });
        });

    Regards,
    Alex Gyoshev
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. UI for ASP.NET MVC is VS 2017 Ready
  4. BigzampanoXXl
    BigzampanoXXl avatar
    60 posts
    Member since:
    Jan 2007

    Posted 15 Jan 2013 Link to this post

    Hi Alex,

    thank you for your solution. Works fine!
Back to Top