RadTextBox/RadDropDownList and the Context Menu

3 posts, 0 answers
  1. Paul B
    Paul B avatar
    15 posts
    Member since:
    May 2013

    Posted 08 Oct 2013 Link to this post

    I have a RadTextBox and RadDropDownList (DropDown style) on a winform and when I right click at runtime the context menu that pops up contains the usual cut/copy/paste items but it also has "Right to left Reading order", "Show Unicode control characters", "Insert Unicode control character", "Open IME" and "Reconversion" items. How can I disable/hide these unwanted context menu items?

    Thanks!
    ~Paul
  2. UI for WinForms is Visual Studio 2017 Ready
  3. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 11 Oct 2013 Link to this post

    Hello guys,

    RadDropDownList hosts the standard text box and you can remove its context menu by assigning a new ContextMenu instance to its ContextMenu property. Here is how to access the inner text box in RadDropDownList and do that:
    radDropDownList1.DropDownListElement.EditableElement.TextBox.TextBoxItem.TextBoxControl.ContextMenu = new ContextMenu();

    I hope this helps.
     
    Regards,
    Stefan
    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 >>
Back to Top