This is a migrated thread and some comments may be shown as answers.

google-like filtering

1 Answer 57 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Mario Turcotte
Top achievements
Rank 1
Mario Turcotte asked on 21 Nov 2008, 05:13 PM
Hello all,

I have cloned the radComboBox demo "google-like filtering". I have 4 columns and it is working pretty well. What I need to do next is to preserve the value of each drop down, when the grid has applied the filtering. This to give the user the ability to drill down the search.

i.e. The grid is populated with Project information and has the following columns;

  • Project Title
  • Project Manager
  • Team Lead
  • Team

I want the user to be able to input/select a Team from the Team drop down, giving a result of all projects under that Team. Then a Team Lead from the Team Lead dropdown based on the previous result. This would give me all the projects for that Team Lead/Team.

In my exemple a Team Lead can lead multiple Teams.

Is there any way to do this?

Thanks in advance, Mario

1 Answer, 1 is accepted

Sort by
0
Yana
Telerik team
answered on 25 Nov 2008, 08:15 AM
Hi Mario,

In the online example "google-like filtering'' the comboboxes use Load-On-Demand mechanism and their values ar not preserved after postback so I suggest to set them with javascript. You can subscribe to OnResponseEnd event of RadAjaxManager and use the foloowing script:

    var comboValues = new Array("""""");  
          
        function OnRespondEnd(sender, args)  
        {  
           var combo = $find(args._postbackControlClientID);  
            for(var i=0; i<3; i++)  
            {  
                 if(Telerik.Web.UI.RadComboBox.ComboBoxes[i] == combo)  
                 {  
                    comboValues[i] = combo.get_text();  
                 }  
                 else 
                    Telerik.Web.UI.RadComboBox.ComboBoxes[i].set_text(comboValues[i]);  
            }  
        }  
      </script> 

I hope this helps.

Kind regards,
Yana
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
ComboBox
Asked by
Mario Turcotte
Top achievements
Rank 1
Answers by
Yana
Telerik team
Share this question
or