pass values using Query string

Posted by Kannan1986 under ASP.NET on 2/1/2010 | Views : 10628 | Status : [Member] | Replies : 2
HI,

i want to pass two values from one web page to another web page using query string. but i want to display that two values in two text boxes in another web page.




Responses

Posted by: Rtpharry on: 2/1/2010 [Member] [MVP] Bronze

Up
0
Down
You can assign the value of the querystring to a textbox in the page load event. Something like:

if(!String.IsNullOrEmpty(Request.QueryString("TextBoxValue"))

{
TextBox1.Text = Request.QueryString("TextBoxValue");
}


If you are using a formview or other databound control then you can also use a QueryStringParameter to capture the query string.

Kannan1986, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Neeks on: 2/4/2010 [Member] Bronze

Up
0
Down
How to pass the value:
http://siteurl?para1=val1&para2=val2

How to get value:
Request.QueryString["para1"];
Request.QueryString["para2"]


Kannan1986, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response