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

button with drop down checkbox list

1 Answer 178 Views
Buttons, RadioButton, CheckBox, etc
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 23 Jul 2013, 05:52 PM
Hi, i need a control that looks like a button.  when clicked it drops down a list of items that have checkboxes next to them so the user can pick one or more.  I'm currently using the radsplitbutton.  it does most of that with the exception of the check box part.  can i add checkboxes to it?

thanks!

1 Answer, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 26 Jul 2013, 01:20 PM
Hello John,

Thank you for writing.

You can add a RadCheckBox to a split button like this:
RadMenuItem item = new RadMenuItem();
item.IsChecked = true;
item.CheckOnClick = true;
this.radSplitButton1.Items.Add(item);

Also you can use the RadMenuHostItem class to add different kind of controls as menu items:
RadLabel label = new RadLabel();
label.Text = "test";
 
RadMenuHostItem hostedItem = new RadMenuHostItem(label);
 
this.radSplitButton1.Items.Add(hostedItem);

I hope this helps. Should you have any other questions do not hesitate to ask.

Regards,
Dimitar
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WINFORMS.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
Buttons, RadioButton, CheckBox, etc
Asked by
John
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
Share this question
or