checkbox listbox

2 posts, 1 answers
  1. Edward
    Edward avatar
    45 posts
    Member since:
    Aug 2005

    Posted 16 Apr 2012 Link to this post

    Hi

    I want to have a checkbox listbox in my vistor dataForm. This checkbox lists the characteristics of a visitor. The checkbox list is a collection of values.

    How can I:

    - add such a control to the DataForm 

    For a drop down, this works.
    if (e.PropertyName == CountryID"
    {
        e.DataField = new DataFormComboBoxField()
                    {
                        ItemsSource = this.GetCountries(),
                        SelectedValuePath = "ID",
                        DisplayMemberPath = "Name",
                        DataMemberBinding = new Binding("CountryID") { Mode = BindingMode.TwoWay }
                    };
    }


    - Where and how can I read those checked values out?


    Hope you can help!

  2. Answer
    Maya
    Admin
    Maya avatar
    4062 posts

    Posted 16 Apr 2012 Link to this post

    Hi Edward,

    You need to define style for RadComboBox and modify its ItemTemplate. Please refer to this forum thread for a reference. Once you create the style, you can set it to the data field you want.   

    Regards,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. DevCraft banner
Back to Top