Click here to Skip to main content
15,899,314 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am using asp.net 2008 .In my form eg:"form1", i enter some details .in that form i have register button.when i press that it goes to registration form.After completing registration it redirect to "form1" .I want to retaining that previously entered details in that form1.
Posted
Comments
Muralikrishna8811 12-Apr-12 4:44am    
That's y we need State Management Concepts to maintain previous page or previous request info in future pages

Just Store that form1 data in session or Viewstate then use that in next page or any where

There is no out of the box feature available in ASP.NET for achieving this.
Do the following this step by step.

1. In the button click handler of Form1 serialize the Form1 data in session and redirect to Form2.
2. When the registration done and the control redirects the user to Form1, in the page Load handler of form1 deserialize the data from session and populate the controls and clear the data from session.


If this solves your problem please mark it as answer.
 
Share this answer
 
Use Javascript history.back(); or history.go(-1); method to achieve this.
The following piece of code should do this :

<a id='acrBack' onclick='javascript:history.back();'>Go back</a>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900