Using Querystring
Querystring is a day old mechanism to pass values across pages. The main advantage of this method is it is very simple. However, disadvantages are the values are visible in the address bar and you can not pass objects this way. This method is best suited when you want to pass small number of values that need not be secured from others. In order to implement this method you will follow these steps:
For Detailed Info Visit
Blog
Create the web form with controls
Provide some button or link button that posts the form back
In the click event of the button create a string that holds URL for another
Add control values to this URL as querystring parameters
Response.Redirect to another form with this URL
private void Button1_Click(object sender, System.EventArgs e)
{
string url;
url="dest.aspx?CustomerName=" + TextBox1.Text + "&EmailAddress=" +TextBox2.Text;
Response.Redirect(url);
}
In the dest.aspx page load you can get the values passed by using
private void Page_Load(object sender, System.EventArgs e)
{
Label1.Text=Request.QueryString["CustomerName"];
Label2.Text=Request.QueryString["EmailAddress"];
}