Is it possible to have different session time outs for different users? I need to have 180 mins session for admin and 20 min for non-admin users. Currently it is single session timeout for all the users. we are using a web.config key
Any help would be appriciated.
Setting
Session.Timeout
property by code will set the timeout on a per user basis.You can manually set
Session.Timeout = 20;
orSession.Timeout = 180;
based on the user type when they log in.This code should work for you:
You can call
SetSessionTime()
after user successfully logs in.