Click here to Skip to main content
15,887,820 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
in my application i am accepting data in one web page and displaying it on other page. i tried this using session variables but as soon as close browser the data that i am displaying goes. basically i want that information to remain even if browser is closed. so what can be done for this.

thank you
Posted

For your requirement, it seems that you have to save the data in your DataBase so that you can retrieve it even after the browser is closed.
 
Share this answer
 
Comments
janwel 24-Jan-12 0:51am    
One of the answers. Why didnt I think of that. ^_^ Im thinking more like adding a cookie with Expires but I dont think it will work ^_^.
you can save your data in data bas and fetch in anther page

OR

you can use cross page post back

please check the link

http://aspdotnetfaq.com/Faq/How-to-make-Cross-Page-Postback-in-ASP-Net.aspx[^]
 
Share this answer
 
It's a state management concept.
Viewstate, Sesion, Querystring, hiddenFields are allow you to pass values between pages but unable to persist information after browser close.
cause when you close browser and reopen it, a new session is assigned with that browser.

To accomplish your task, you need to take use of Cookies or databse or store value in extrafile that will persist your data.
 
Share this answer
 
use cookies so that your data remains in state.
 
Share this answer
 
There is three ways to solve this problem..

1. You can go for file input/output. There you can write the data in the files on client computer..

2. Or else you should save your data in database, and try to access it from there.

3. Or else you can use cookies.

Try whichever you think easy...
 
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