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

[Solved] Rad Prometheous ComboBox control

3 Answers 153 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
yuri
Top achievements
Rank 1
yuri asked on 21 Jan 2008, 07:35 PM
Dear Telerik,
In your code library you published solution for the ComboBox and CheckBoxes in order to get multiselection.
I did the following:
1. Took your solution
2. Changed ComboBox to Prometheous ComboBox
As a result I do not see text against textboxes.

Moreover, if previously I could access individual check box using:
var id = document.getElementById(combo.Items[i].ClientID + "_CheckBox");
I cannot do this not as combo box item does not implement any ClientID or similar functionality.

Would you please explain how can I use Prometheous combobox with check boxes in order to implement multiselection.

Thank you very much,
Yuri

3 Answers, 1 is accepted

Sort by
0
Rosi
Telerik team
answered on 22 Jan 2008, 01:43 PM
Hi Yuri,

Please find attached simple project illustrating that everything works as expected on our side.

Hope this helps.

Kind regards,
Rosi
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
yuri
Top achievements
Rank 1
answered on 22 Jan 2008, 02:16 PM
Dear Rosi,
Your example does work. Thanks a lot. The difference is that:
1. You do binding on the server side - on Page_Load. Why? With ASP.NET Combobox I should not do it if I declare my items in aspx file.
2. How to determine whether check box is checked or not on the client side (javascript code). You do it on the server side with method GetCheckedItems(). In my previous e-mail I showd how it could be done with ASP.NET combo.

Thanks a lot,
Yu
0
Rosi
Telerik team
answered on 22 Jan 2008, 03:24 PM
Hello Yuri,

Below are the answers of your questions.

1. DataBinding of RadComboBox "Prometheus" items is necessary when DataBinder.Eval method is used in the templates.

2. You can check are the checkboxes checked by the following way:
      function GetCheckedItems()  
        {  
            var combo = $find("RadComboBox1");  
            var i = 0;  
            for(i= 0;i<combo.get_items().get_count(); i++)  
            {  
          
                var id ="RadComboBox1_i"+i+"_CheckBox";  
                alert(document.getElementById(id).checked);  
            }  
        }  
        </script> 

All the best,
Rosi
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
ComboBox
Asked by
yuri
Top achievements
Rank 1
Answers by
Rosi
Telerik team
yuri
Top achievements
Rank 1
Share this question
or