How To pass values from one page to other page in sharepoint..(two different webparts present in two different pages)programmatically with c#.....
Normally, to pass or transfer the data from one page to other page we use the familiar concept called (QueryString).....
Using of query string is described bellow.....
In first webpart or in page one, where we get the value:
Here we have to write the redirected page url and passed value as the following
this.page.response.redirect("url?value="+value);
example:
this.page.respose.redirect("vm:5555/_layouts/pages/login.aspx?username="+gowtham);
Then in second page, we have to write as follow:
page_Load()
{
String user = this.page.request.QueryString["username"];
}
now we can use that particular value of user in the second page.
if you want to validate that particular value across page you have to use the "ViewState".....
all the best happy coding
