简体   繁体   中英

How exchange data between each page in ASP.NET and C#

I'm new to ASP.NET and C# and I want to create simple webapp. How can I exchange data from a form between different webpage? Like for example, I'm inputing a data in a form from my page1.aspx, then I want to go to a different page, like page2.aspx, then I want to click the back link button to go to the page1.aspx but my data is still save in the form.

Thanks.

You can keep the data in the session variable. Session varaible values will remains till the session ends.You can keep the form values in the session variable and use that again when you come back to the page to load the form fields.

http://msdn.microsoft.com/en-us/library/ms972429.aspx

Try this link to maintain the state in asp.net and exchanging the values from one web page to another webpage.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM