This is a migrated thread and some comments may be shown as answers.

Disable expand RadMenu

1 Answer 63 Views
Menu
This is a migrated thread and some comments may be shown as answers.
Lux
Top achievements
Rank 1
Lux asked on 24 Mar 2016, 11:17 AM

Hello,

My special scenario is as follows:

A topMenu with sublinks and a boxmenu with this sublinks on the page. I don't want to show the sublinks as expanded dropdown in the topMenu. The user should only one click on the top menu to reach the subpage, where the boxMenu will be visible. The links on the box menu should be "connected" with the topMenu to let the topLink as marked.

So my idea, let the topMenu expanding disabled. I have created two sitemapProviders web.sitemapTop and web.siteMapBox with the related structure.

With "expanding" the top-menu, all works fine. But I want to avoid expanding the TopMenu because of design-reasons (surely a bit user unfriendly...).

When I delete the submenuItems from the TopSiteMap, the boxLinks don't let the TopMenuLink as marked...

How can I disable the expand functionality of a radmenu (asp.net)?

Thanks in advance.

 

regards,

lux

1 Answer, 1 is accepted

Sort by
0
Ivan Danchev
Telerik team
answered on 25 Mar 2016, 02:40 PM
Hello Lux,

The Menu's sub-menus expand functionality cannot be disabled, however, the expansion can be cancelled. If you subscribe to the Menu's OnClientItemOpening you would be able to cancel this event with the set_cancel() method and the submenus will not be expanded when clicking on the root items:
function OnClientItemOpening(sender, args) {
    args.set_cancel(true);
}


Regards,
Ivan Danchev
Telerik
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
Tags
Menu
Asked by
Lux
Top achievements
Rank 1
Answers by
Ivan Danchev
Telerik team
Share this question
or