ASP.NET Page 属性
控件标准属性参考手册
定义和用法
Page 属性获取对包含控件的 Page 实例的引用。该属性的值反映了包含控件的 .aspx 文件的名称。
实例
下面的实例显示包含 Button 控件的 Page:
<script runat="server">
Sub Button1_Click(sender As Object, e As EventArgs)
Response.Write("The Page containing the button is: ")
Response.Write(button1.Page)
End Sub
</script>
<form runat="server" >
<asp:Button ID="button1" OnClick="Button1_Click"
Text="Get Page" runat="server" />
</form>
Sub Button1_Click(sender As Object, e As EventArgs)
Response.Write("The Page containing the button is: ")
Response.Write(button1.Page)
End Sub
</script>
<form runat="server" >
<asp:Button ID="button1" OnClick="Button1_Click"
Text="Get Page" runat="server" />
</form>
演示实例 »
控件标准属性参考手册其他扩展