FormsAuthentication.SignOut() results inSystem.NullReferenceException

Discussion in 'Microsoft ASP .NET' started by Alex Diaz, Aug 22, 2010.

  1. Alex Diaz

    Alex Diaz Guest

    Hi. I am getting a "System.NullReferenceException" when I call
    FormsAuthentication.SignOut() from Session_End method in global.asax.
    Code is as follow:

    void Session_End(object sender, EventArgs e)
    {

    FormsAuthentication.SignOut();
    this.Session["user"] = null;
    Response.Redirect("login.aspx");

    }

    Any ideas why this could be happening?
    Thanks.
     
    Alex Diaz, Aug 22, 2010
    #1
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jeff Johnson

    FormsAuthentication.SignOut not working within subfolder

    Jeff Johnson, Aug 5, 2003, in forum: Microsoft ASP .NET
    Replies:
    5
    Views:
    494
    Jeff Johnson
    Aug 6, 2003
  2. Ali
    Replies:
    1
    Views:
    203
    Egbert Nierop \(MVP for IIS\)
    Jan 29, 2004
  3. xiko tripa

    Problems with FormsAuthentication.SignOut()

    xiko tripa, Mar 29, 2004, in forum: Microsoft ASP .NET
    Replies:
    4
    Views:
    817
    xiko tripa
    Mar 30, 2004
  4. Ed West

    FormsAuthentication.SignOut not working

    Ed West, Aug 23, 2004, in forum: Microsoft ASP .NET
    Replies:
    0
    Views:
    276
    Ed West
    Aug 23, 2004
  5. Signout does not signout.

    , Apr 4, 2006, in forum: Microsoft ASP .NET
    Replies:
    2
    Views:
    170
Loading...

Share This Page