母版页contentPlaceHolder [英] master page && contentPlaceHolder

查看:69
本文介绍了母版页contentPlaceHolder的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我遇到一个问题,每当我在CSharp.Net Web应用程序中添加任何母版页时.发生以下错误...


I am facing a problem that whenever I add any Master Page in CSharp.Net Web Application. The following error occurs...

Error Rendering Control - ContentPlaceHolder1
An unhandled exception has occured
This control can only be used in a MasterPage.



请帮我解决这个问题. :sigh:



please help me what i do with this problem. :sigh:

推荐答案

签出您的解决方案路径.可能有'#'登录您的路径.重命名文件夹并删除#号,然后再次签出.


问候,
马来·科塔里(Malay Kothari).
iammalay@yahoo.com
check out your solution path. There might be '#' sign in your path. Rename folders and remove # signs and check out again.


Regards,
Malay Kothari.
iammalay@yahoo.com


好像您将contentplaceholder面板放置在主面板之外.

将contentplaceholder移到母版页面板中并尝试.
Looks like you are placing your contentplaceholder panel outside the master panel.

Move the contentplaceholder into the master page panel and try.


请确保选中``母版页''复选框,然后为要添加的每个页面选择相应的母版.请勿将任何内容占位符放置在其他任何页面中(即不构成母版页.
快乐编程;-)
Be sure that you select check box use Master page and select the corresponding Master to each pages you add.And checkout that you didn''t place any content place holders in any other page(ie which doesn''t ingerit a Master page.
Happy Programming;-)


这篇关于母版页contentPlaceHolder的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆