clearing session variables

Results 1 to 4 of 4

Thread: clearing session variables

  1. #1
    PJ Guest

    Default clearing session variables

    Is there a way to clear all session variables in a single command, without directly identifying each one? Something like Session.Contents = Empty?<BR><BR>I ask because I use session variables to move data through a series of pages then write to a db. The way I have it now, it&#039s possible that a user who submits a form and returns to the first page to fill out a fresh form has not cleared the session. Therefore, elements that were defined earlier may still be present. They are simply too many form elements to clear them individually. Upon writing to the db, I&#039d like to just reset or clear all variables in the session. Can this be done?<BR><BR><BR>

  2. #2
    Join Date
    Dec 1969
    Los Angeles, CA

    Default RE: clearing session variables


  3. #3
    PJ Guest

    Default Thanks!


  4. #4
    Join Date
    Dec 1969

    Default *MAY* BE WRONG ANSWER!

    Session.Abandon *also* abandons the Session.SessionID. Essentially making the user start over from scratch. This might be what you want, but if you *only* want to clear out the values of session variables, then see<BR><BR><BR><BR>which, just incidentally, is in the topic "Sessions" in the ASPFAQs. And you can get to the ASPFAQs by clicking on the link at the top right of this page.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts