METHOD: Session.Abandon
Session.Abandon
The Abandon method terminates a user session, destroys
all the objects in the current Session object, and releases its
resources. However, this deletion will not occur until all of
the script is processed for the current page. When the session
ends, the OnEnd event handler is called. By default, even
if you do not call Abandon, the Session object is
terminated after twenty minutes of idle time.
Code:
----------------File1.asp-------------------
<%
Response.Write "Your SessionID is " & Session.SessionID
Session("Application") = "DevSite"
Session.Abandon
Response.Write "The Application name is " & Session("Application")
%>
----------------File2.asp---------------------
<%
Response.Write "Your SessionID is " & Session.SessionID
%>
Output:
------------File1.asp-------------------------
Your SessionID is 465107831
The Application name is DevSite
-----------File2.asp--------------------------
Your SessionID is 465107831
Copyright 1999-2001 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information
|