Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#2.0 ASP.NET
I am working on concurrent login in asp.net for that m maintaining one table with a flag. as soon as the user logs in it gets inserted in table with flag as '1' .Till this flag remains '1' ,no other user with same credentials can logs in and at the time of log out and session expiry m updating the table n making it '0' so that other user can log.
but there are two situation arising where the flag will remain 1.
1.When user closes the browser without log out.
2.when user navigates/changes the url.
 

 
so i just want to know will the session end at the specific time if the browser is closed before timeout or what will happen actually to session when browser is closed..?
 

plz help....thanx in advance
Posted 13-Jun-12 3:16am
Zupr!y@312
Edited 13-Jun-12 3:19am
v2

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

hi,
When you close your browser it I think the session still exists on the server. And once the timeout has elapsed it gets deleted.
 
What brought me to this conclusion? check the below link
 
http://msdn.microsoft.com/en-us/library/ms972429.aspx[^]
 
best Luck
  Permalink  
Comments
Zupr!y@ at 13-Jun-12 8:45am
   
i have one doubt suppose i m executing a stored procedure at session_end(global.asax) to update my table and updating flag as '0'(my session time out is 10 mins).Now i closed the window before 10 mins so the proc which m caling at session_end will run after 10 min my table will ge updated ryt.?

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

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 420
1 OriginalGriff 210
2 Kornfeld Eliyahu Peter 210
3 DamithSL 210
4 mukesh mourya 85
0 OriginalGriff 7,215
1 DamithSL 5,199
2 Maciej Los 4,866
3 Sergey Alexandrovich Kryukov 4,757
4 Kornfeld Eliyahu Peter 4,514


Advertise | Privacy | Mobile
Web02 | 2.8.141223.1 | Last Updated 13 Jun 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100