asp.net.ph

HttpStaticObjectsCollection.Item Property

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.

Arguments [ JScript ]

name
The case-insensitive name of the object to get.

Parameters

name
The case-insensitive name of the object to get.

Property Value

An object from the collection.

Example

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" ];
See Also

HttpStaticObjectsCollection Members   HttpApplicationState.StaticObjects Property Skip Navigation Links




Home
Suggested Reading


Previous page Back to top Next page

© 2000-2010 Rey Nuñez All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note

You can help support asp.net.ph