RadTreeview - node click(Urgent)

4 posts, 0 answers
  1. Sindu
    Sindu avatar
    46 posts
    Member since:
    Oct 2011

    Posted 16 Nov 2011 Link to this post


    Hi,

    I have a radtreeview .it has 3 Treenode .I have a RadTreelist inside the node template .how to expand the treelist when I expand the treenode ? or In which treenode event should be used for this purpose?

    Thanks

    Sindu.
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 17 Nov 2011 Link to this post

    Hello,

    You can try the following code snippet.
    C#:
    protected void tree_NodeClick(object sender, Telerik.Web.UI.RadTreeNodeEventArgs e)
       {
           e.Node.Expanded = true;
           RadTreeList list = (RadTreeList)e.Node.Nodes[0].FindControl("RadTreelist1");
           list.ExpandAllItems();
       }

    Thanks,
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Sindu
    Sindu avatar
    46 posts
    Member since:
    Oct 2011

    Posted 17 Nov 2011 Link to this post

    Hi Princy,

    Thanks for your reply ...
    I have used the below code for node click.But when I click the treeview node ,that event node_click is not fired .
    Should I give anything in the .aspx (design)?

    Thanks

    Sindu.
  5. Tsvetina
    Admin
    Tsvetina avatar
    1876 posts

    Posted 22 Nov 2011 Link to this post

    Hi Sindu,

    Can you confirm that you have set AutoPostBack="true" for the RadTreeView control? This is needed in order to get postbacks (and the NodeClick event) on clicking a node.

    Greetings,
    Tsvetina
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
Back to Top