Example #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            defaultPage = (Page_Controls)Session["Permission"];
            if (Context.User.Identity.IsAuthenticated)
            {
                HttpContext.Current.GetOwinContext().Authentication.SignOut(
                    OpenIdConnectAuthenticationDefaults.AuthenticationType,
                    CookieAuthenticationDefaults.AuthenticationType);
            }

            if (Session["Permission"] != null)
            {
                string lstmsg = string.Empty;

                LstActivityTrack.AppFeature = "Logout";
                LstActivityTrack.UserID     = defaultPage.UserId;
                LstActivityTrack.FacilityID = defaultPage.FacilityID;
                LstActivityTrack.MachineID  = GetIPAddress.GetMachineAddress();
                LstActivityTrack.IPAddress  = GetIPAddress.GetDeviceAddress();


                lstmsg = lclsService.ActivityTracker(LstActivityTrack);
                Session["Permission"] = null;
            }
        }