TemplateControl.Eval Method (String, String)
.NET Framework 3.0
Evaluates a data-binding expression using the specified format string to display the result.
Namespace: System.Web.UI
Assembly: System.Web (in system.web.dll)
Assembly: System.Web (in system.web.dll)
protected String Eval ( String expression, String format )
protected internal function Eval ( expression : String, format : String ) : String
Not applicable.
Parameters
- expression
The navigation path from the container to the public property value to place in the bound control property.
- format
A .NET Framework format string to apply to the result.
Return Value
A string that results from the evaluation of the data-binding expression and conversion to a string type.| Exception type | Condition |
|---|---|
|
The data-binding method can only be used for controls contained on a Page. | |
|
expression is a null reference (Nothing in Visual Basic). - or - expression is an empty string (""). |
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.
Community Additions
ADD
Show: