Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6198349
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T03:58:54+00:00 2026-05-24T03:58:54+00:00

I defined my session variable, in my Global.asax called user like this protected void

  • 0

I defined my session variable, in my Global.asax called user like this

    protected void Session_Start(object sender, EventArgs e)
    {
        Session["idMap"] = "";
        Session["user"] = "";
    }

Also i have a asp:Login in where i set the value of the session variable in the event of loggedIn

    protected void lgnMapZone_LoggedIn(object sender, EventArgs e)
    {
        Session.Abandon();
        Session["user"] = lgnMapZone.UserName;
    }

My problem it’s that when the users it’s autenthicated, the void session_start it’s called and erase my variable, how can i solved this??

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T03:58:55+00:00Added an answer on May 24, 2026 at 3:58 am

    Session.Abandon() destroys the session and the Session_OnEnd event is triggered. You should call this method when the user does a logout instead of log in.

    You should probably call Session.Clear() which just removes all values (content) from the session Object while logging in.

    This will resolve the issue that you have now.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I’ve defined a session variable in my Session_Start procedure void Session_Start(object sender, EventArgs e)
I am having trouble with a session id not being defined. The session variable
i have a session variable -${reData.totalCharge} it may have values like 000000033 . when
I tried setting a variable like this: $test_id = mysql_insert_id($dbc); because I wanted to
User-Defined Functions & Collating Sequences Full support for user-defined functions and collating sequences means
In a user defined wizard page, is there a way to capture change or
I am creating a multipage form in PHP, using a session. The $stage variable
I have defined the global nls_date_format on Oracle 10.2 XE as follows: alter system
The Form variable in my form is being passed/retrieved via Session. I have a
I can use isset($var) to check if the variable is not defined or null.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.