DisplayNameExtensions.DisplayNameFor Method
Gets the display name for the model.
Updated 13 March 2011
Assembly: System.Web.Mvc (in System.Web.Mvc.dll)
| Name | Description | |
|---|---|---|
![]() ![]() | DisplayNameFor(Of TModel, TValue)(HtmlHelper(Of TModel), Expression(Of Func(Of TModel, TValue))) | Gets the display name for the model. |
![]() ![]() | DisplayNameFor(Of TModel, TValue)(HtmlHelper(Of IEnumerable(Of TModel)), Expression(Of Func(Of TModel, TValue))) | Gets the display name for the model. |
DisplayNameExtensions.DisplayNameFor(Of TModel, TValue) Method (HtmlHelper(Of TModel), Expression(Of Func(Of TModel, TValue)))
Gets the display name for the model.
<ExtensionAttribute> Public Shared Function DisplayNameFor(Of TModel, TValue) ( html As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, TValue)) ) As MvcHtmlString
Parameters
- html
-
Type:
System.Web.Mvc.HtmlHelper(Of TModel)
The HTML helper instance that this method extends.
- expression
-
Type:
System.Linq.Expressions.Expression(Of Func(Of TModel, TValue))
An expression that identifies the object that contains the display name.
Type Parameters
- TModel
The type of the model.
- TValue
The type of the value.
DisplayNameExtensions.DisplayNameFor(Of TModel, TValue) Method (HtmlHelper(Of IEnumerable(Of TModel)), Expression(Of Func(Of TModel, TValue)))
Gets the display name for the model.
<ExtensionAttribute> Public Shared Function DisplayNameFor(Of TModel, TValue) ( html As HtmlHelper(Of IEnumerable(Of TModel)), expression As Expression(Of Func(Of TModel, TValue)) ) As MvcHtmlString
Parameters
- html
-
Type:
System.Web.Mvc.HtmlHelper(Of IEnumerable(Of TModel))
The HTML helper instance that this method extends.
- expression
-
Type:
System.Linq.Expressions.Expression(Of Func(Of TModel, TValue))
An expression that identifies the object that contains the display name.
Type Parameters
- TModel
The type of the model.
- TValue
The type of the value.
Show:

