Disable automatic expanding of tree node

2 posts, 0 answers
  1. Greg
    Greg avatar
    17 posts
    Member since:
    Mar 2009

    Posted 01 Oct 2009 Link to this post

    Is it possible to disable automatic expanding of a tree node?

    When I select a folder that has children, the explorer automatically opens that tree. I don't want that to happen. I only want the tree to expand if the user explicitly clicks the "+" plus button.

    Greg
  2. Fiko
    Admin
    Fiko avatar
    1406 posts

    Posted 06 Oct 2009 Link to this post

    Hi Greg,

    You can cancel expanding of the folders in the TreeView by using this approach :
    • attach a handler to the OnClientFolderChange event
    • then cancel the event by using this code :
      <script type="text/javascript"
          function OnClientFolderChange(oExplorer, args) 
          { 
              args.set_cancel(true); 
          } 
      </script> 

    I hope this helps.

    Best wishes,
    Fiko
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Back to Top