Dela via


HtmlHelper<TModel>.DisplayNameFor<TResult> Method

Definition

Returns the display name for the specified expression.

public:
generic <typename TResult>
 virtual System::String ^ DisplayNameFor(System::Linq::Expressions::Expression<Func<TModel, TResult> ^> ^ expression);
public string DisplayNameFor<TResult> (System.Linq.Expressions.Expression<Func<TModel,TResult>> expression);
abstract member DisplayNameFor : System.Linq.Expressions.Expression<Func<'Model, 'Result>> -> string
override this.DisplayNameFor : System.Linq.Expressions.Expression<Func<'Model, 'Result>> -> string
Public Function DisplayNameFor(Of TResult) (expression As Expression(Of Func(Of TModel, TResult))) As String

Type Parameters

TResult

The type of the expression result.

Parameters

expression
Expression<Func<TModel,TResult>>

An expression to be evaluated against the current model.

Returns

A String containing the display name.

Implements

Applies to