Solved

ASP.NET Session data after crash

Posted on 2013-12-17
5
560 Views
Last Modified: 2014-01-02
I have a web application written in C#, ASP.NET.
The application is not stable and sometimes crashes when users are using it.
After the crash the user brings up the application's logon screen again.
I am storing the session data in the Session object provided by ASP.NET.
Question :
Is it possible to retrieve information of the previous session (the one that crashed) when new logon screen is loading ?
0
Comment
Question by:vu3lmg
  • 3
  • 2
5 Comments
 
LVL 29

Expert Comment

by:Paul Jackson
ID: 39725012
No, a crash in a web application will cause the process running the website to restart and therefore lose all of the session data.
The alternative is to store session information in sql server so it can be retrieved after a crash.
0
 
LVL 1

Author Comment

by:vu3lmg
ID: 39725122
Dear jacko72
My question is about extracting the information from the client PC, not the server.
0
 
LVL 29

Expert Comment

by:Paul Jackson
ID: 39725157
Session state is stored on the server not on the client, a client based solution would be to use cookies.
0
 
LVL 1

Author Comment

by:vu3lmg
ID: 39725411
Yes session state is stored on the web-server but even that web-server would use cookies to identify between different users.  Right ?  
I am trying get that information (cookie) after the failure.

Please bare with me for the silly questions / lack of proper terminology, but I am new to the web programming.
0
 
LVL 29

Accepted Solution

by:
Paul Jackson earned 500 total points
ID: 39725518
The session cookies that a web-server uses are usually in-memory or transient cookies which are kept in temporary so they are lost when a browser is closed or due to a crash.
It is possible to get around this by writing your own cookies to the client or using state server management to manage session state

http://www.beansoftware.com/ASP.NET-Tutorials/Store-Session-State-Server.aspx
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This video discusses moving either the default database or any database to a new volume.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now