Posted on: 11/12/2013 5:30:54 AM | Views : 727

Hi all,
I am mainting the users at application level using application level variable so that only one particaluar user can login

on login i  add the user session to hashtable which is further stored in HttpContext.Current.Application["table"]
table = new Hashtable(); table.Add(userName, Session["userid"]);
 HttpContext.Current.Application["table"] = table;

on logout/session time out(null) i m doing this
obj.LogOutSession(Convert.ToString(Session["userid"]));  //method called is below in which i am removing the session from application variable FormsAuthentication.SignOut(); FormsAuthentication.RedirectToLoginPage();

public void LogOutSession(string objUser) { if (objUser != string.Empty) { Hashtable table = HttpContext.Current.Application ...

Go to the complete details ...