protected bool Login() { mmUserManager User = mmAppBase.Factory.CreateUserManager(); if (User.AuthenticateUser(this.Username,this.Password, mmAppBase.DatabaseMgr.GetSecurityDatabaseKey()) ) { // Set the value up here Session["mmUserSecurity_UserPk"]=User.UserPK; // *** Simply exit here now which forces page to reload as is // *** and then redirect to the source page Session.Remove("mmUserSecurity_RedirectionUrl"); // If a Language PK is specified, save it to the mmCurrentLanguage session variable if (User.CurrentLanguage != null) { Session["mmCurrentLanguage"] = User.CurrentLanguage; } // Call the HookUserAuthenticated method this.HookUserAuthenticated(mmAppBase.UserMgr.UserPK);