HttpApplicationState.Get HttpApplicationState.Get HttpApplicationState.Get HttpApplicationState.Get Method

Definition

Gets an HttpApplicationState object by name or index.

Overloads

Get(Int32) Get(Int32) Get(Int32) Get(Int32)

Gets an HttpApplicationState object by numerical index.

Get(String) Get(String) Get(String) Get(String)

Gets an HttpApplicationState object by name.

Get(Int32) Get(Int32) Get(Int32) Get(Int32)

Gets an HttpApplicationState object by numerical index.

public:
 System::Object ^ Get(int index);
public object Get (int index);
member this.Get : int -> obj
Public Function Get (index As Integer) As Object

Parameters

index
Int32 Int32 Int32 Int32

The index of the application state object.

Returns

The object referenced by index.

Examples

The following example returns the first object (index = 0) from the HttpApplicationState collection of the intrinsic Application object and copies it to a new object variable.

Object MyObject;
MyObject = Application.Get(0);
   
Dim MyObject As Object
MyObject = Application.Get(0)

Get(String) Get(String) Get(String) Get(String)

Gets an HttpApplicationState object by name.

public:
 System::Object ^ Get(System::String ^ name);
public object Get (string name);
member this.Get : string -> obj
Public Function Get (name As String) As Object

Parameters

name
String String String String

The name of the object.

Returns

The object referenced by name.

Remarks

The following example returns an object named MyAppVar1 from the HttpApplicationState collection of the intrinsic Application object and copies it to a new object variable.

Dim MyObject As Object  
MyObject = Application.Get("MyAppVar1")  
Object MyObject;  
MyObject = Application.Get("MyAppVar1");  

Applies to