navigation Menu Module help

Feb 4, 2011 at 2:07 PM
Edited Feb 4, 2011 at 2:44 PM


 i'm trying to make  a module which will display the current menu / child menu

but i dont find a  way to access properly to the navigation items


Could you help me ?


I'm currently trying to do :

var menuParts = contentManager.Query<MenuPart, MenuPartRecord>().Where(x => x.OnMainMenu).List();

from my SiteMapMenuHandler method


but each time  my breakpoint on this line is reached, the hanlder is call back ...

any idear ?


Thanks !




Feb 4, 2011 at 7:27 PM

You should take a look at the code for this module:

Feb 5, 2011 at 12:57 PM

Also be sure and take a look at: by Piotr Szmyd.



Feb 8, 2011 at 8:34 AM
Edited Feb 8, 2011 at 12:51 PM

I can currently get labels of the menu using the same provider than HierarchicalMainMenu (the only difference is the navigation builder , i make a new instance because i cant find a  way to get the current one)

But i'm currently meeting a new problem:

each Href and Url of my objects are empty, so my menu is finally a Menu name provider...


Moreover, how can i get the current page ? i've seen during debug some objects with a current bool but not in menuPart


A question which is not related to the others :

is that possible to manage the visibility of a widget from js, and make other part of the design fill the blank made by the widget which disapear ?

thanks for helping !


PS: i'm really sorry for my poor english ^^

Feb 19, 2011 at 5:19 PM

What do you mean by creating a new instance of the NavigationBuilder? If you create your own menu provider, then you have a method named GetNavigation(NavigationBuilder builder), which is the place where rendering should happen. The method gets called and an appropriate builder is passed as a parameter from the navigation manager when it needs a menu to be rebuilt. So you have a current builder here.

Can you elaborate more about the current page problem - what you want to achieve?

About the widget - surely this is possible with some use of jQuery - check the jQuery UI page for more info.