AreaRegistrationContext.MapRoute Method (String, String)

Maps the specified URL route and associates it with the area that is specified by the AreaName property.

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

member MapRoute : 
        name:string * 
        url:string -> Route

Parameters

name
Type: System.String

The name of the route.

url
Type: System.String

The URL pattern for the route.

Return Value

Type: System.Web.Routing.Route
A reference to the mapped route.

ExceptionCondition
ArgumentNullException

The url parameter is a null reference (Nothing in Visual Basic).

Show: