I have a Master page that contains a custom property, defined as follows:
Public Property SelectedNavigationID() As String
Set(ByVal value As String)
Me.leftnavNavigation.SelectedNavigationID = value
As you can see, this property is used to set the value of a property of one
of the Master page's Controls. I set the property from the Content page as
Private Sub Page_PreInit(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.PreInit
Me.Master.SelectedNavigationID = "menuConditionalValidator"
The problem occurs in the Set method of the property defined in the Master
page; it tells me that Me.leftnavNavigation has a value of Nothing, which
obviously prevents me from setting the property. I know that I am missing
something simple, because this is almost exactly the same as a previous
version of the site I am recreating, which works perfectly. What could be
causing the problem? Any help would be appreciated. Thanks.