共用方式為


RouteCollection.GetRouteData(HttpContextBase) 方法

定義

傳回集合中符合指定值的路徑相關資訊。

public:
 System::Web::Routing::RouteData ^ GetRouteData(System::Web::HttpContextBase ^ httpContext);
public System.Web.Routing.RouteData GetRouteData (System.Web.HttpContextBase httpContext);
member this.GetRouteData : System.Web.HttpContextBase -> System.Web.Routing.RouteData
Public Function GetRouteData (httpContext As HttpContextBase) As RouteData

參數

httpContext
HttpContextBase

封裝 HTTP 要求相關資訊的物件。

傳回

包含路由定義值的物件。

例外狀況

contextnull

context 參數中,物件的 Request 屬性是 null

適用於

另請參閱