Radtreeview in Radcombobox

2 posts, 0 answers
  1. Djb
    Djb avatar
    3 posts
    Member since:
    Jan 2012

    Posted 28 Feb 2012 Link to this post


    I am trying to solve a very simple thing but somehow not able to get it working. 

    I have a RadComboBox and radtreeview as one of its items. Now, I want to enable user to select only the leaf node. I have marked "Postback" attribute to false if the node is not leaf. so it solves the purpose of firing an event. 

    Now , what is happening is, when user clicks parent node, it expands the node but then disappears. so user again have to click the combo box to select. 

    Is there anyway i can disable the disappearing of radtreeview in combo box ? 

    I have attached some screenshot and my code. I want my dropdown list to look like Pic-2 when i click the parent node. Currently it looks like Pic-1 after i click the parent node. 

    Code : OnClientNodeClicking

     var node = eventArgs.get_node();
        if (node.get_level() != 2) {
    return; }

    Please help.
  2. Plamen
    Plamen avatar
    2810 posts

    Posted 01 Mar 2012 Link to this post

    Hello Djb,

    I have added a similar code to the one that you posted to the code of our RadTreeView in RadCombobox demo and it worked as expected. Here you can see a video of the test:

    function nodeClicking(sender, args) {
               var node = args.get_node();
               if (node.get_level() != 2) {
               var comboBox = $find("<%= RadComboBox1.ClientID %>");
               var node = args.get_node()

    If the behavior you want to achieve is somehow different please try to explain it once again. 

    Plamen Zdravkov
    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