System.Web Namespace HttpStaticObjectsCollection Class
Gets the object with the specified name from the collection.
In [ C# ], this property is the indexer for the HttpStaticObjectsCollection class.
[ VB ]
Public Default ReadOnly Property Item ( _
ByVal name As String _
) As Object
[ C# ]
public object this [
string name
] {get;}
[ C++ ]
public: __property Object* get_Item (
String* name
);
[ JScript ]
returnValue = HttpStaticObjectsCollectionObject.Item ( name );
-or-
returnValue = HttpStaticObjectsCollectionObject ( name );
In [ JScript ], you can use the default indexed properties defined by a type, but you cannot explicitly define your own. However, specifying the expando attribute on a class automatically provides a default indexed property whose type is Object and whose index type is String.
- name
- The case-insensitive name of the object to get.
- name
- The case-insensitive name of the object to get.
An object from the collection.
The following example retrieves an object named ArrayList1 from the StaticObjects collection and copies it to an object variable.
[ VB ]
Dim myObject As Object
myObject = Application.StaticObjects ( "ArrayList1" )
[ C# ]
Object myObject;
myObject = Application.StaticObjects [ "ArrayList1" ];
HttpStaticObjectsCollection Members HttpApplicationState.StaticObjects Property