This Blog defines how to send data using ? sign in the address bar.
Request object
Request object are used to carry data from client to server. To manage the data, Request provides QueryString collection. passing variables content between pages ASP.NET gives us several choices. One choice is using QueryString property of Request Object.
For example:
Add the following code on the form load.
VB Code:
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Request.QueryString("n") IsNot Nothing Then
Dim n As Integer = Integer.Parse(Request.QueryString("n"))
For i As Integer = 1 To 10
Response.Write(i * n & "<br>")
Next
End If
End Sub
Now save and run the application. address bar show the following address http://localhost:1963/WebForm1.aspx.
Data is send using ? sign in the address bar. Now write the below URL address to the above window and than execute.
http://localhost:1963/WebForm1.aspx?n=4

Figure1

Join the conversation! Your thoughts help the community grow.