Retrieving SiteMap Menu Name from Master Page, ASP.Net 2.0, VS 2005?

L

Luqman

I have setup a Menu using Master Page, and I want to retrieve the name of
the selected Menu.

I tried using following code in Page.Master,

Protected Sub MainMenu_MenuItemClick Event

Session("MyMenu")=mainmenu.SelectedItem.Text

End Sub

But the above code is not working.

My menu control is linked with Sitemap Datasource.

My requirement is just to put the selected menu name in the Session
Variable, and then go to the desired page.

Any idea please ?

Best Regards,

Luqman
 
L

Luqman

I got it, this can be achieved with :-

session("Menu")=sitemap.currentnode.title

Best Regards,

Luqman
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top