自分のを<body>
自分に公開したい。したがって、私はします:Master Page
Content Pages
Master.aspx
<body id="MasterPageBodyTag" runat="server">
Master.aspx.vb
Public Property Messaging() As Messaging
Get
Return mMessaging
End Get
Set(ByVal value As Messaging)
mMessaging = value
End Set
End Property
Public Property BodyTag() As HtmlGenericControl
Get
Return MasterPageBodyTag
End Get
Set(ByVal value As HtmlGenericControl)
MasterPageBodyTag = value
End Set
End Property
ContentPage.aspx
<%@ MasterType VirtualPath="~/my.master" %>
ContentPage.aspx.vb
Master.BodyTag.Attributes.Add("onload", "MyScript()")
ただし、コンテンツページにが表示されないだけでなく、以前は正しく機能していたプロパティBodyTag
にアクセスできないというエラー(エラー:マスターのメンバーではありません)が表示されます。原因は何ですか?Messaging