• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 251
  • Last Modified:

Seesion Expire

How do I set the session to expire in vb.net
thank you
0
yalamanchir
Asked:
yalamanchir
  • 2
  • 2
  • 2
  • +1
1 Solution
 
ramesh12Commented:
session.abandon
0
 
gregoryyoungCommented:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspnet/html/asp12282000.asp explains well (and is a good overall article) ... if you look in your web.config  there is a line that looks like ..

<sessionstate
      mode="inproc"
      cookieless="false"
      timeout="20"
      sqlconnectionstring="data source=127.0.0.1;user id=<user id>;password=<password>"
      server="127.0.0.1"
      port="42424"
  />


change the value of the timeout="" field.
0
 
gregoryyoungCommented:
whoops I think I read the question wrong ... session.abandon is correct.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
DotNetLover_BaanCommented:
If you want to set a time for the session to expire...
Session.TimeOut = 5 'Will expire in 5 mins
0
 
iboutchkineCommented:
DotNet
I thought that 5 min will be 5*60*1000 = 300000
or am I wrong?
0
 
DotNetLover_BaanCommented:
nope... TimeOut property takes integer and set it in minutes... (not it milli seconds, as we have in Timer object)
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfSystemWebSessionStateHttpSessionStateClassTimeoutTopic.asp

-Baan
0
 
iboutchkineCommented:
I probably got confused because in JavaScript it is in milliseconds. I am using

window.setTimeout("alert('you will be logged off in 5sec');",5000);
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 2
  • 2
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now