📜  从母版页访问内容页面 - 无论代码示例

📅  最后修改于: 2022-03-11 14:56:36.186000             🧑  作者: Mango

代码示例1
ContentPlaceHolder contentPage = Page.MasterPage.FindControl("ContentPlaceHolder1") as ContentPlaceHolder;
Label lblHead =(Label)contentPage.FindControl("lblHeading");
Response.Write(lblHead.Text);