Ask Learn
Preview
Please sign in to use this experience.
Sign inThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides support for parsing and evaluating a data-binding expression against an object at run time.
Eval(String) |
Evaluates a data-binding expression. |
Eval(String, String) |
Evaluates a data-binding expression using the specified format string to display the result. |
Evaluates a data-binding expression.
protected public:
System::Object ^ Eval(System::String ^ expression);
protected internal object Eval(string expression);
member this.Eval : string -> obj
Protected Friend Function Eval (expression As String) As Object
The navigation path from the container to the public property value to place in the bound control property.
An object that results from the evaluation of the data-binding expression.
The data-binding method can be used only for controls contained on a Page.
The value of expression
must evaluate to a public property.
The Eval method calls the DataBinder.Eval method using the GetDataItem method to resolve the object reference that the expression is evaluated against.
Product | Versions |
---|---|
.NET Framework | 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
Evaluates a data-binding expression using the specified format string to display the result.
protected public:
System::String ^ Eval(System::String ^ expression, System::String ^ format);
protected internal string Eval(string expression, string format);
member this.Eval : string * string -> string
Protected Friend Function Eval (expression As String, format As String) As String
The navigation path from the container to the public property value to place in the bound control property.
A .NET Framework format string to apply to the result.
A string that results from the evaluation of the data-binding expression and conversion to a string type.
The data-binding method can only be used for controls contained on a Page.
The value of expression
must evaluate to a public property.
The Eval method calls the Eval method using the GetDataItem method to resolve the object reference that the expression is evaluated against.
Product | Versions |
---|---|
.NET Framework | 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET feedback
.NET is an open source project. Select a link to provide feedback:
Please sign in to use this experience.
Sign in