如何从子页面编辑母版页 div?
与此命令等效的 DIV 是什么?
((Panel)this.Page.Master.FindControl("Panel1")).Style.Add("display", "none");
这对于面板来说效果很好,但我找不到用我知道 ID 的 DIV 做同样事情的变体。有人知道吗?
预先感谢您的帮助!
what's the DIV equivalent to this command?
((Panel)this.Page.Master.FindControl("Panel1")).Style.Add("display", "none");
This works great with a panel but I can't find the variation for doing the same thing with a DIV who's ID I know. anyone know?
thanks in advance for the help!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

发布评论
评论(3)
~没有更多了~
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
Div属于System.Web.UI.HtmlControls命名空间的HtmlGenericControl类。
并且母版页中的 div 控件应该是
runat="server"
谢谢
Asif
Div belongs to HtmlGenericControl class of System.Web.UI.HtmlControls namespace.
and your your div control in master page sholud be
runat="server"
Thanks
Asif