Tom Gullen
Tom Gullen

Reputation: 61725

Reference public object in nested content page

My page structure is:

MainNew (Master Page)
|
-->  Store (Nested Master Page)
     |
     -->  StoreCheckout.aspx (Content Page)

MainNew has the declaration

public LoggedInUser ThisUser { get; set; }

I can access this property in the Nested Masterpage as follows:

((MasterPages_MainNew)Master).ThisUser

But I can't seem to work out how to reference ThisUser from the content page. Can anyone show me the syntax?

Upvotes: 0

Views: 57

Answers (1)

Massimiliano Peluso
Massimiliano Peluso

Reputation: 26737

((MasterPages_MainNew)this.Master.Master).ThisUser

Upvotes: 2

Related Questions