Quick References
ADO
ASP
CSS2
HTML
JavaScript
Jet SQL
VBScript
WML
WMLScript
WSH
XHTML
XML DOM
XSLT
Features
Knowledge Base
Tutorials
Partners
ZVON.ORG
XML
Planet Source Code
VisualBuilder
Web Design
Your HTML Source
XML/XSLT Forums
ASPAlliance
Scripts
Programmers Heaven
Tek-Tips Forums
Developer Fusion
Code Project
RemoveAll Method
Session Object
All Objects
All Properties
Session.Contents
METHOD: Session.Contents.Remove
Implemented in version 3.0
Session.
Contents.Remove
(Name|Integer)
The
Contents.Remove
method is used to delete one specified item in the
Session.Contents
collection.
You may use only one of the two possible choices for the mandatory argument.
Name
or
Integer
The
Name
argument is the name of the item to be deleted. It must be enclosed in a pair of quotes.
The
Integer
argument is the position number of the item in the collection to be deleted. The numbering sequence for a collection starts at one, not zero.
Code:
<%
Session("name") = "Session Maker"
Session("publishdate") = "05/15/01"
Session("author") = "DevGuru"
Session.Contents.Remove
(1)
Session.Contents.Remove
("publishdate")
For Each Item in Session.Contents
Response.Write Item & "=" & Session.Contents(Item) & "<BR>"
Next
%>
Output:
author=DevGuru
Copyright 1999-2005 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information