Hi,
I have been searching for an answer for this but have not really got anything to work.
What do be done:
A submenu (made through the use of a menulist in an ascx), where you can select which page to be selected disregarding of the page that is actually selected. (the pageid to actually be selected in the menu is available).
I guess I somehow need to set(override?) the CurrentPage and return the page of the page to actually be displayed. But I have absolutely no idea of how to do this.
Somehow I think I have to make this in the codebehind file? :)
Any help appreciated (even if its only a hint of where to start looking).
/Marcus
Hi Mikael,
Thank you very much for your input, It steered me in the right direction, I didnt even think about setting the CurrentPage.PageLink before(I had only tried setting the MenuControl.PageLink property). I now managed to get it to work properly (how simple once you see it:)
For other people that want to do this, this is how I did it:
In the codebehind file I did this:
Page_Load function:
if(!IsPostBack)
{
MenuListControl.PageLink = YourMenuRootPageReference;
MenuListControl.CurrentPage.PageLink = PageToBeSelectedReference,
MenuListControl.DataBind();
}
And I removed any bindings in the first :menulist in the ascx file (no pagelink there).
-marcus