C
Chung Hang Shum
I'm a beginner in ASP.Net. I'd wroten mange asp code before and now I
need to transfer them from asp to asp.Net.
In classical ASP you can write code like this:
<% If strRequest = "ConfirmPasswd" then%>
<TABLE border="0" class="ContentArea" width="100%">
<TR><TD>Change Password?</TD></TR>
</TABLE>
<TABLE border="0" cellPadding="2" class="ContentArea" width="100%">
<TR><TD width="27">
<form method="post" action="MyPage.asp?action=DoPasswd" id=form3
name=form3>
<input type="submit" value="OK" id=submit2 name=submit2>
</form></TD><TD>
<form method="post" action="MyPage.asp">
<input type="submit" value="Cancel">
</form>
</TD></TR></TABLE>
<% ElseIf strRequest = "DoPasswd" Then%>
<TABLE border="0" cellPadding="2" class="ContentArea" width="100%">
<TR><TD colSpan=2>Your password is changed.<br>
Your new password is: <b><%=update_password%></b><br>
</TD></TR>
<TR><TD>
<form method="post" action="MyPage.asp">
<input type="submit" value="OK">
</form>
</TD></TR></TABLE>
<% ElseIf strRequest = "something" Then%>
...........
<% End if %>
How can I do this in ASP.Net? I write in C# and use code-behind.
I have tried Literal control, but it didn't work. All I got is a
hidden input field with name _ViewState.
Can somebody help me please?
Chung Hang Shum
need to transfer them from asp to asp.Net.
In classical ASP you can write code like this:
<% If strRequest = "ConfirmPasswd" then%>
<TABLE border="0" class="ContentArea" width="100%">
<TR><TD>Change Password?</TD></TR>
</TABLE>
<TABLE border="0" cellPadding="2" class="ContentArea" width="100%">
<TR><TD width="27">
<form method="post" action="MyPage.asp?action=DoPasswd" id=form3
name=form3>
<input type="submit" value="OK" id=submit2 name=submit2>
</form></TD><TD>
<form method="post" action="MyPage.asp">
<input type="submit" value="Cancel">
</form>
</TD></TR></TABLE>
<% ElseIf strRequest = "DoPasswd" Then%>
<TABLE border="0" cellPadding="2" class="ContentArea" width="100%">
<TR><TD colSpan=2>Your password is changed.<br>
Your new password is: <b><%=update_password%></b><br>
</TD></TR>
<TR><TD>
<form method="post" action="MyPage.asp">
<input type="submit" value="OK">
</form>
</TD></TR></TABLE>
<% ElseIf strRequest = "something" Then%>
...........
<% End if %>
How can I do this in ASP.Net? I write in C# and use code-behind.
I have tried Literal control, but it didn't work. All I got is a
hidden input field with name _ViewState.
Can somebody help me please?
Chung Hang Shum