Share via


AreaRegistrationContext.State Property

Gets an object that contains user-defined information to pass to the area.

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

Syntax

'Declaration
Public Property State As Object
    Get
    Private Set
public Object State { get; private set; }
public:
property Object^ State {
    Object^ get ();
    private: void set (Object^ value);
}

Property Value

Type: System.Object
An object that contains user-defined information to pass to the area.

Remarks

The State property enables you to pass any type of information to the area that is being registered. For example, you might want to pass some or all of the following information:

  • A reference to the HttpApplication object.

  • Repository information.

  • A reference to a log.

  • A reference to an Inversion of Control (IOC) container.

See Also

Reference

AreaRegistrationContext Class

System.Web.Mvc Namespace