SessionStateItemCollection.RemoveAt Method (Int32)

 

Deletes an item at a specified index from the collection.

Namespace:   System.Web.SessionState
Assembly:  System.Web (in System.Web.dll)

public void RemoveAt(
	int index
)

Parameters

index
Type: System.Int32

The index of the item to remove from the collection.

Exception Condition
ArgumentOutOfRangeException

index is less than zero.

- or -

index is equal to or greater than Count.

If the SessionStateItemCollection collection does not contain an element with the specified name, the collection remains unchanged. No exception is thrown.

.NET Framework
Available since 2.0
Return to top
Show: