Home > Code > ASP.NET > Access master page controls from content page?

Access master page controls from content page?

by Thamil   on Jan 25, 2012   Category: ASP.NET   |  Views: 1153    |  Points: 25   |  Gold 



sometimes we need to access the master page controls in content pages, see the below sample code how to access master page control from content page.

Label lblName = (Label)Master.FindControl("lblUsername");
lblName.Text = "Test Name";



Post Code  |  Code Snippet Home

User Responses


No response found, be the first to review this code snippet.

Submit feedback about this code snippet

Please sign in to post feedback

Latest Posts