RadMenuItem BackColor only visible on mouse over

2 posts, 0 answers
  1. scottw
    scottw avatar
    21 posts
    Member since:
    Oct 2010

    Posted 04 Sep 2013 Link to this post

    I am trying to set the background color of a RadMenuItem based on some logic in order to highlight a particular item in the menu. To set the highlighted item color I am doing this:

    menuItem.FillPrimitive.BackColor = Color.Gray;


    The problem is this coloring only is visible when the mouse moves over the item. I want the coloring to apply to all states. Is there something else that must be done for this to appear in non-hover states?
  2. Nikolay
    Admin
    Nikolay avatar
    1804 posts

    Posted 05 Sep 2013 Link to this post

    Hello Scott,

    Because of the specific design they are after, not all themes may share the same set of settings, therefore the solution for you may depend on which theme you are using. However, the most common setting to be applied in this situation is the Visibility property set to Visible:

    this.radMenuItem1.FillPrimitive.BackColor = Color.Red;
    this.radMenuItem1.FillPrimitive.Visibility = Telerik.WinControls.ElementVisibility.Visible;

    I hope this helps. If you still need assistance, please let me know which theme you are using, so that I can provide you with adequate assistance.
    Regards,
    Nikolay
    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