RouteCollection.MapPageRoute Method (String, String, String, Boolean)
.NET Framework (current version)
Provides a way to define routes for Web Forms applications.
Assembly: System.Web (in System.Web.dll)
member MapPageRoute : routeName:string * routeUrl:string * physicalFile:string * checkPhysicalUrlAccess:bool -> Route
Parameters
- routeName
-
Type:
System.String
The name of the route.
- routeUrl
-
Type:
System.String
The URL pattern for the route.
- physicalFile
-
Type:
System.String
The physical URL for the route.
- checkPhysicalUrlAccess
-
Type:
System.Boolean
A value that indicates whether ASP.NET should validate that the user has authority to access the physical URL (the route URL is always checked). This parameter sets the PageRouteHandler.CheckPhysicalUrlAccess property.
This method is provided for coding convenience. It is equivalent to calling the Add method and passing a Route object that is created by using the PageRouteHandler class.
The following example shows how to define a route by using this method. This example is part of a larger example that is available in the MapPageRoute method overview.
.NET Framework
Available since 4.0
Available since 4.0
Show: