ch07-02-01.aspx
来自「这是一个asp.net的全文教程.里面还有数据库的数据.对初学者有很大的帮助」· ASPX 代码 · 共 38 行
ASPX
38 行
<Html>
<Head>
<Script Language = "VB" Runat = "Server" >
' Page对象的Load事件
Sub Page_Load(obj As Object, e As Eventargs)
ShowEvent("发生Page对象的Load事件<Br>")
End Sub
' Page对象的Init事件
Sub Page_Init(obj As Object, e As Eventargs)
ShowEvent("发生Page对象的Init事件<Br>")
End Sub
' Page对象的Page_PreRender事件
Sub Page_PreRender(Sender As Object, e As Eventargs)
ShowEvent("发生Page对象的PreRender事件<Br>")
End Sub
' Page对象的Unload事件
Sub Page_Unload(obj As Object, e As Eventargs)
ShowEvent("发生Page对象的Unload事件")
End Sub
Sub ShowEvent(ByVal Msg As String)
Dim strA As String = DSP_MSG.text
strA = Msg
DSP_MSG.Text = DSP_MSG.Text & Space(4) & strA
End Sub
Sub Button_Click(obj As Object, e As Eventargs)
ShowEvent("用户单击确定按钮")
End Sub
</Script>
</Head>
<Body>
<Form Runat="Server">
<asp:Button ID="Button" Text="确定" OnClick="Button_Click"
Runat="Server" />
</Form>
<asp:Label ID="DSP_MSG" Text="" Runat="Server" />
</Body>
</Html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?