Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

DisplayExtensions.DisplayFor Method

Returns HTML markup for each property in the object that is represented by the Expression expression.

This member is overloaded. For complete information about this member, including syntax, usage, and examples, click a name in the overload list.

  Name Description
Public method Static member DisplayFor<TModel, TValue>(HtmlHelper<TModel>, Expression<Func<TModel, TValue>>) Returns HTML markup for each property in the object that is represented by the Expression expression.
Public method Static member DisplayFor<TModel, TValue>(HtmlHelper<TModel>, Expression<Func<TModel, TValue>>, Object) Returns a string that contains each property value in the object that is represented by the specified expression, using additional view data.
Public method Static member DisplayFor<TModel, TValue>(HtmlHelper<TModel>, Expression<Func<TModel, TValue>>, String) Returns a string that contains each property value in the object that is represented by the Expression, using the specified template.
Public method Static member DisplayFor<TModel, TValue>(HtmlHelper<TModel>, Expression<Func<TModel, TValue>>, String, Object) Returns a string that contains each property value in the object that is represented by the specified expression, using the specified template and additional view data.
Public method Static member DisplayFor<TModel, TValue>(HtmlHelper<TModel>, Expression<Func<TModel, TValue>>, String, String) Returns HTML markup for each property in the object that is represented by the Expression, using the specified template and an HTML field ID.
Public method Static member DisplayFor<TModel, TValue>(HtmlHelper<TModel>, Expression<Func<TModel, TValue>>, String, String, Object) Returns HTML markup for each property in the object that is represented by the specified expression, using the template, an HTML field ID, and additional view data.
Top
Show:
© 2015 Microsoft