in asp.net
i have a master page in this a Menu controls
i want that in one form when i click on other page button the i want to edit menu itms text.
how can i do this?
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Jaish MathewsPosted Apr 30, 2010, 1:34 AM
You going through wrong logics. The purpose of Menu and Master page it self is pages should be controlled from Master page. You are saying you want to control/modify Master page from child.
Amit ChoudharyPosted Apr 30, 2010, 1:33 AM
you can access the master page control in child page.
Case first when you have single master page.
Label L1=(Label)this.Master.FindControl("Label1");if you have multiple or nested master pages.
then it becomes quite complex here..
first you have to find the content place holder of super master page then you'll find the control of second master page...
ContentPlaceHolder p1=(ContentPlaceHolder)this.Master.Master.FindContro("ContentPlaceHolder1");Label L1=(Label)P1.FindControl("Label1");
Hope you get the idea.. how to access the control of master into child.
Please mark "Do you like this post" if it helps you.