01.
<%@ Page Language=
"C#"
Debug=
"true"
%>
02.
<script runat=
"server"
>
03.
04.
void
Page_Load()
05.
{
06.
if
(!Page.IsPostBack)
07.
{
08.
this
.lblText.Text =
"IsPostBack = False"
;
09.
}
10.
else
11.
{
12.
this
.lblText.Text =
"IsPostBack = True"
;
13.
}
14.
}
15.
16.
17.
</script>
18.
<html>
19.
<head>
20.
</head>
21.
<body>
22.
<form runat=
"server"
>
23.
<asp:Label id=
"lblText"
runat=
"server"
></asp:Label><br />
24.
<asp:Button id=
"Button1"
runat=
"server"
Text=
"Button"
></asp:Button>
25.
<br /><br /><br />
26.
<asp:HyperLink ID=
"HyperLink1"
runat=
"server"
NavigateUrl=
"IsPostBack.aspx"
>Re-Link</asp:HyperLink></div>
27.
</form>
28.
</body>
29.
</html>