Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

breadcrumbs

Posted on 2014-03-06
4
Medium Priority
?
204 Views
Last Modified: 2014-03-24
Hi  all,

I'm trying to setup a breadcrumb in an asp.net vb website in vs2010.   I'm using master pages, aswell as nested master pages...

I'm using the below code for the master page using the web form's page_load, this works fine... even though isn't there a way to use the Page directive's Title tag?


sub page_load
    Dim lblBreadCrumbs As Label  = CType(Master.FindControl("lblBreadCrumbs"), Label)
    lblBreadCrumbs.Text = "Home Page"
end sub

This works fine on the webform one level down from the master page with the lblBreadCrumbs label control existing in the masterpage.

However, how do i access this same label control in a nested master page, another level down?

is there a better way of achieving breadcrumbs in a nested master page website?

Thanks,
0
Comment
Question by:ErinTheCoderGirl
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 39909023
This page shows examples of ways to access master page controls

http://msdn.microsoft.com/en-us/library/xxwa0ff0.aspx
0
 

Author Comment

by:ErinTheCoderGirl
ID: 39909165
Hi - I've gone through the 4 examples in the download script from that page,  None of them answer my problem, they only reference how to access masterpage from the one level down... and not nested master pages, as I'm using.

Example 2 was the closest, but their solution is what I'm already using, as above.


Any ideas that relate directly to nested master pages?
0
 

Author Comment

by:ErinTheCoderGirl
ID: 39911978
Anyone want to have a go at this one?
0
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 2000 total points
ID: 39912159
As mentioned in your other question, you can go up the hierarchy using

me.Master.Master.Master...
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (http://www.ecb.europa.eu/stats/exch…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question