RouteUrlExpressionBuilder::EvaluateExpression Method (Object^, BoundPropertyEntry^, Object^, ExpressionBuilderContext^)
Creates a URL that corresponds to specified URL parameter values and to a route URL format.
Assembly: System.Web (in System.Web.dll)
public: virtual Object^ EvaluateExpression( Object^ target, BoundPropertyEntry^ entry, Object^ parsedData, ExpressionBuilderContext^ context ) override
Parameters
- target
-
Type:
System::Object^
Not used in this implementation.
- entry
-
Type:
System.Web.UI::BoundPropertyEntry^
The property that the expression is bound to.
- parsedData
-
Type:
System::Object^
Not used in this implementation.
- context
-
Type:
System.Web.Compilation::ExpressionBuilderContext^
Properties for the control or page.
Return Value
Type: System::Object^The URL that corresponds to the specified URL parameter values and to the selected route. The route is selected by matching route URL patterns to the specified list of parameters. In case more than one route matches a specified list of parameters, a route name can also be specified to indicate which route to select.
ASP.NET calls this method when an expression of the following form is encountered in markup:
<%$ RouteUrl: urlparameter=value %>
This method generates the appropriate URL for the specified route-key values for the current Route object. This method overrides the EvaluateExpression method. It gets from the entry parameter a reference to the control to which the expression is bound, it gets from the context parameter the expression to be evaluated, and it calls the GetRouteUrl method to generate the URL.
Available since 4.0