473,395 Members | 1,986 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

session expired

Hi,
I have a question on how to deal with session expiration.
What i want to do is when the session variable expiration, i need to do
some database change. How can i do this?

I appreciate in advance.
Nov 18 '05 #1
3 2279
Use the Session_OnEnd event handler (in your global.asax class).

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living

"Green" <so*****@yahoo.com> wrote in message news:opsd180k1mpk4u20@dev-02...
Hi,
I have a question on how to deal with session expiration.
What i want to do is when the session variable expiration, i need to do
some database change. How can i do this?

I appreciate in advance.

Nov 18 '05 #2
Session_OnEnd but was know to be unreliable under ASP. Also it fires once
the timeout is reached (20 mn).

Other options are to do something when a window closes. My personal
preference is to see if I really need to perform real time housekeeping or
if it can be done as a background task (for example the SQL state server
uses a scheduled proc that runs every few minutes to clean up expired
session).

Patrice

--

"Green" <so*****@yahoo.com> a écrit dans le message de
news:opsd180k1mpk4u20@dev-02...
Hi,
I have a question on how to deal with session expiration.
What i want to do is when the session variable expiration, i need to do
some database change. How can i do this?

I appreciate in advance.

Nov 18 '05 #3
> Session_OnEnd but was know to be unreliable under ASP. Also it fires once
the timeout is reached (20 mn).
Whatever you think you know about ASP, you can't apply it to ASP.Net, and
"unreliable" is a characterization. Can you define "unreliable" in terms of
behavior, results, anything factual?

Session_OnEnd has never fired ater 20 minutes. It has always (with both ASP
and ASP.Net) fired EXACTLY when the Session ends. That would be (be default)
20 minutes AFTER the last browser request from the client.

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
I get paid good money to
solve puzzles for a living

"Patrice" <no****@nowhere.com> wrote in message
news:ui**************@TK2MSFTNGP14.phx.gbl... Session_OnEnd but was know to be unreliable under ASP. Also it fires once
the timeout is reached (20 mn).

Other options are to do something when a window closes. My personal
preference is to see if I really need to perform real time housekeeping or
if it can be done as a background task (for example the SQL state server
uses a scheduled proc that runs every few minutes to clean up expired
session).

Patrice

--

"Green" <so*****@yahoo.com> a écrit dans le message de
news:opsd180k1mpk4u20@dev-02...
Hi,
I have a question on how to deal with session expiration.
What i want to do is when the session variable expiration, i need to do some database change. How can i do this?

I appreciate in advance.


Nov 18 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: David B | last post by:
Hi, Could somebody please tell me how I check whether a session is dead based soley on the Session.SessionID. At present the timeout is set to 20 minutes in IIS, I am aware that I can reset...
6
by: Keith | last post by:
Is there any way of detecting whether a session variable does not exist because it expired or because it simply did not exist in the first place? Thanks
3
by: Simon | last post by:
Hi all, Any help with this would be much appreciated: I have a site where the session needs to timeout because of security concerns. I want to send the user back to the login page if the...
4
by: Nick | last post by:
Hi I am a little stuck. I have a web app which uses cookieless session management. I would like to inform a user when their session has ended but cannot work out how to implement. I thought...
6
by: NH | last post by:
How can I warn a user that their session has expired when they click on a button etc?
17
by: Riaan | last post by:
Hi guys! I have an issue that needs urgent resolution. Imagine this scenario: You have: 1 production server running Windows Server 2003, IIS6 and an instance of MSDE 2000. There is an...
2
by: rsouza | last post by:
Hi. Recently here in my work we added the following code in the Global.asax file to handled the session expired and redirect users to the home of the site explaining them the occurred (some...
2
by: Gordon Burditt | last post by:
I had this idea about preventing session fixation, and I'm wondering what anyone else thinks about it. The idea is, essentially, don't allow session ids that YOUR PHP didn't generate (and aren't...
1
by: magix8 | last post by:
Hi, I have a portal with logon session coded in ASP. From the Portal Main screen, i access to a popup-window screen to do my activity. Whenever session expired, the popup-window screen will...
4
by: sriram | last post by:
Hello Friends, I am new to this group so big HIIIIIIII to all :) fine i have a serious doubt about session handling in PHP. After 20 min (default time) session getting expired, session values...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.