web 2.0

ASP.NET(vb.net) Request.Form() - Request Object

ASP.NET(vb.net) Request.Form() - Request.Form() : The Form collection retrieves the values of form elements posted to the HTTP request body, with a form using the POST method.

ShotDev Focus:
- ASP.NET(vb.net) Request.Form()

Syntax


Request.Form(element)[(index)|.Count]

Example

AspNetRequestForm.aspx

<%@ Page Language="VB" %>
<script runat="server">
Sub btnButton1_Click(sender As Object, e As EventArgs)
Me.lblText.Text = Request.Form("txtName")
End Sub

</script>
<html>
<head>
<title>ShotDev.Com Tutorial</title>
</head>
<body>
<form runat="server">
<input type="text" name="txtName" value='<%=Request.Form("txtName")%>'>
<br />
<asp:Button id="btnButton1" onclick="btnButton1_Click" runat="server" Text="Button"></asp:Button>
<hr />
<asp:Label id="lblText" runat="server"></asp:Label><br>
</form>
</body>
</html>

Screenshot

ASP.NET(vb.net) Request.Form()
.
.
.
Download this script.
Download

1 Star2 Stars3 Stars4 Stars5 Stars6 Stars7 Stars8 Stars9 Stars10 Stars (No Ratings Yet)
Loading ... Loading ...

Leave a Reply

You must be logged in to post a comment.