Highlight Selected Rad Menu Item

5 posts, 1 answers
  1. Mahesh
    Mahesh avatar
    7 posts
    Member since:
    Nov 2012

    Posted 16 Nov 2012 Link to this post

    Hi,
    I want to Highlight the selected Rad Menu item from my menu. But i'm unable to highlight it. I have added 'checked' Visual State in NavBarTopLevelItemTemplate but still not help. Any help on how to highlight the selected menu item?

     

     

  2. Rosen Vladimirov
    Admin
    Rosen Vladimirov avatar
    640 posts

    Posted 19 Nov 2012 Link to this post

    Hi Mahesh,

    Your code looks fine - I prepared a simple example with it and the SelectedItem is highlighted in Green. I'm attaching it for your reference. Maybe you are setting the IsCheckable value to false for the TopLevelItems and it is preventing the "Checked" and "Unchecked" state.

    Please check the attachment and inform me if you still have problems with your application.

    Kind regards,
    Rosen Vladimirov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. DevCraft banner
  4. Mahesh
    Mahesh avatar
    7 posts
    Member since:
    Nov 2012

    Posted 22 Nov 2012 Link to this post

    Hi Rosen,
            Thanks for your response. The solution provided by you is working partially.
    Initially it's highlighting the selected item, but when i move my mouse over the Selected item it's triggering Highlighted Visual State and on mouse leave it's coming to normal state even though my menu item is still in selected state. Is there a way to keep it in Checked state even after mouse leave event?
    Regards,
    Mahesh.
  5. Answer
    Rosen Vladimirov
    Admin
    Rosen Vladimirov avatar
    640 posts

    Posted 22 Nov 2012 Link to this post

    Hi Mahesh,

    You cannot modify the same property in two different VisualStateGroups. That's why I've modified your project and now when an item is checked the background will be Green. If the items is highlighted, the foreground will be red.

    Please check the attached project and inform me if you still have any concerns.

    Greetings,
    Rosen Vladimirov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  6. Mahesh
    Mahesh avatar
    7 posts
    Member since:
    Nov 2012

    Posted 23 Nov 2012 Link to this post

    Hi Rosen,
        Thnx for the solution. It's works the way i'm expecting.
    Regards,
    Mahesh.
Back to Top
DevCraft banner