如何在已创建的.aspx页面中添加母版页 [英] How can i add a master page to already created .aspx page
本文介绍了如何在已创建的.aspx页面中添加母版页的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
Hii对所有人来说,我开发了一个项目,在设计时我自己在很多页面中包含母版页内容。我想要为已经创建的两个页面添加母版页内容。我试过添加内容占位符,但它不起作用。请帮助我如何做到这一点..........提前感谢
关于
D RAmu
解决方案
如果您创建了一个母版页,要创建一个新的Web窗体,您可以通过以下条款:
< ![CDATA [<% @ Page 语言 = vb AutoEventWireup = false CodeBehind = CadMetasLoja.aspx.vb 继承 = SAC_BESNI.ConsMetasLoja MasterPageFile = 〜/ MasterPrincipal.Master % > ]]>
只需将MasterPageFile =../ Admin.master
添加到.aspx页面的页面指令
,然后根据您的要求添加内容占位符
Hii to all,iam developing a project where i incuded master page content in so many pages at the design time itself.Hear i want to add master page content for two more pages which whear already created. I have tried by adding content place holder but it is not working.please help me how can i do this..........thanks in advance
with regards
D RAmu
解决方案
If you''ve created a Master Page, to create a new Web Form you can just by the following clause:
<![CDATA[<% @ Page Language = "vb" AutoEventWireup = "false" CodeBehind = "CadMetasLoja.aspx.vb" Inherits = "SAC_BESNI.ConsMetasLoja" MasterPageFile = "~ / MasterPrincipal.Master"%>]]>
Just addMasterPageFile="../Admin.master"
to your page directive of .aspx page
and then add content placeholder according to ur requirement
这篇关于如何在已创建的.aspx页面中添加母版页的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文