Click event not working for RadMenuItem

2 posts, 0 answers
  1. SivaPrasad Bevara
    SivaPrasad Bevara avatar
    73 posts
    Member since:
    Oct 2012

    Posted 22 Sep 2010 Link to this post

    Hi,

    I am using Telerik 4 version and facing the following problem with RadMenuItem click events.

    I am trying to use “MouseLeftButtonUp,  MouseLeftButtonDown,  MouseRightButtonDown and  MouseRightButtonUp "  events and these are not working with the RadMenu control.

    <TelerikNavigation:RadMenu x:Name="MainMenu" Height="30" BorderThickness="1">
                 <TelerikNavigation:RadMenuItem x:Name="Home" 
                                MouseLeftButtonUp="Home_MouseLeftButtonUp" 
                                MouseLeftButtonDown="Home_MouseLeftButtonDown" 
                                MouseRightButtonDown="Home_MouseRightButtonDown" 
                                MouseRightButtonUp="Home_MouseRightButtonUp" Header="Home">
                </TelerikNavigation:RadMenuItem>
                 <TelerikNavigation:RadMenuItem x:Name="About" Header="About">
                      <TelerikNavigation:RadMenuItem x:Name="Aboutus" Header="About us" 
                            MouseLeftButtonUp="Home_MouseLeftButtonUp" 
                            MouseLeftButtonDown="Home_MouseLeftButtonDown" 
                            MouseRightButtonDown="Home_MouseRightButtonDown" 
                            MouseRightButtonUp="Home_MouseRightButtonUp" >
                    </TelerikNavigation:RadMenuItem>
                  <TelerikNavigation:RadMenuItem x:Name="Contactus" Header="Contact us" ></TelerikNavigation:RadMenuItem>
             </TelerikNavigation:RadMenuItem>
                <TelerikNavigation:RadMenuItem x:Name="Login" Header="Logout" ></TelerikNavigation:RadMenuItem>
    </TelerikNavigation:RadMenu>

    These events are not firing when I click on the Menu Items.

    How I can use these events.

    Please help.

    Regards,
    SivaPrasad.B

  2. Valeri Hristov
    Admin
    Valeri Hristov avatar
    2252 posts

    Posted 22 Sep 2010 Link to this post

    Hi,

    You cannot use those events because RadMenuItem is handling them (the same happens with a standard Button). You should use the Click event on RadMenuItem or ItemClick on RadMenu.

    All the best,
    Valeri Hristov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. DevCraft banner
Back to Top