button with drop down checkbox list

2 posts, 0 answers
  1. John
    John avatar
    60 posts
    Member since:
    Nov 2006

    Posted 23 Jul 2013 Link to this post

    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!
  2. Dimitar
    Admin
    Dimitar avatar
    1415 posts

    Posted 26 Jul 2013 Link to this post

    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 >>
  3. UI for WinForms is Visual Studio 2017 Ready
Back to Top