EditorExtensions.EditorFor EditorExtensions.EditorFor EditorExtensions.EditorFor Method

Definition

Overloads

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String, Object)

Returns an HTML input element for each property in the object that is represented by the expression, using the specified template, HTML field name, and additional view data.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String)

Returns an HTML input element for each property in the object that is represented by the Expression expression, using the specified template and HTML field name.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, Object)

Returns an HTML input element for each property in the object that is represented by the expression, using the specified template and additional view data.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String)

Returns an HTML input element for each property in the object that is represented by the Expression expression, using the specified template.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, Object)

Returns an HTML input element for each property in the object that is represented by the expression, using additional view data.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>)

Returns an HTML input element for each property in the object that is represented by the Expression expression.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String, Object)

Returns an HTML input element for each property in the object that is represented by the expression, using the specified template, HTML field name, and additional view data.

public static System.Web.Mvc.MvcHtmlString EditorFor<TModel,TValue> (this System.Web.Mvc.HtmlHelper<TModel> html, System.Linq.Expressions.Expression<Func<TModel,TValue>> expression, string templateName, string htmlFieldName, object additionalViewData);
static member EditorFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, 'Value>> * string * string * obj -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function EditorFor(Of TModel, TValue) (html As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, TValue)), templateName As String, htmlFieldName As String, additionalViewData As Object) As MvcHtmlString
Type Parameters
TModel

The type of the model.

TValue

The type of the value.

Parameters
html
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,TValue>>

An expression that identifies the object that contains the properties to display.

templateName
String String String

The name of the template to use to render the object.

htmlFieldName
String String String

A string that is used to disambiguate the names of HTML input elements that are rendered for properties that have the same name.

additionalViewData
Object Object Object

An anonymous object that can contain additional view data that will be merged into the ViewDataDictionary<TModel> instance that is created for the template.

Returns

An HTML input element for each property in the object that is represented by the expression.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, String)

Returns an HTML input element for each property in the object that is represented by the Expression expression, using the specified template and HTML field name.

public static System.Web.Mvc.MvcHtmlString EditorFor<TModel,TValue> (this System.Web.Mvc.HtmlHelper<TModel> html, System.Linq.Expressions.Expression<Func<TModel,TValue>> expression, string templateName, string htmlFieldName);
static member EditorFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, 'Value>> * string * string -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function EditorFor(Of TModel, TValue) (html As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, TValue)), templateName As String, htmlFieldName As String) As MvcHtmlString
Type Parameters
TModel

The type of the model.

TValue

The type of the value.

Parameters
html
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,TValue>>

An expression that identifies the object that contains the properties to display.

templateName
String String String

The name of the template to use to render the object.

htmlFieldName
String String String

A string that is used to disambiguate the names of HTML input elements that are rendered for properties that have the same name.

Returns

An HTML input element for each property in the object that is represented by the expression.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String, Object)

Returns an HTML input element for each property in the object that is represented by the expression, using the specified template and additional view data.

public static System.Web.Mvc.MvcHtmlString EditorFor<TModel,TValue> (this System.Web.Mvc.HtmlHelper<TModel> html, System.Linq.Expressions.Expression<Func<TModel,TValue>> expression, string templateName, object additionalViewData);
static member EditorFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, 'Value>> * string * obj -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function EditorFor(Of TModel, TValue) (html As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, TValue)), templateName As String, additionalViewData As Object) As MvcHtmlString
Type Parameters
TModel

The type of the model.

TValue

The type of the value.

Parameters
html
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,TValue>>

An expression that identifies the object that contains the properties to display.

templateName
String String String

The name of the template to use to render the object.

additionalViewData
Object Object Object

An anonymous object that can contain additional view data that will be merged into the ViewDataDictionary<TModel> instance that is created for the template.

Returns

An HTML input element for each property in the object that is represented by the expression.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, String)

Returns an HTML input element for each property in the object that is represented by the Expression expression, using the specified template.

public static System.Web.Mvc.MvcHtmlString EditorFor<TModel,TValue> (this System.Web.Mvc.HtmlHelper<TModel> html, System.Linq.Expressions.Expression<Func<TModel,TValue>> expression, string templateName);
static member EditorFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, 'Value>> * string -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function EditorFor(Of TModel, TValue) (html As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, TValue)), templateName As String) As MvcHtmlString
Type Parameters
TModel

The type of the model.

TValue

The type of the value.

Parameters
html
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,TValue>>

An expression that identifies the object that contains the properties to display.

templateName
String String String

The name of the template to use to render the object.

Returns

An HTML input element for each property in the object that is represented by the expression.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, Object) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>, Object)

Returns an HTML input element for each property in the object that is represented by the expression, using additional view data.

public static System.Web.Mvc.MvcHtmlString EditorFor<TModel,TValue> (this System.Web.Mvc.HtmlHelper<TModel> html, System.Linq.Expressions.Expression<Func<TModel,TValue>> expression, object additionalViewData);
static member EditorFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, 'Value>> * obj -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function EditorFor(Of TModel, TValue) (html As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, TValue)), additionalViewData As Object) As MvcHtmlString
Type Parameters
TModel

The type of the model.

TValue

The type of the value.

Parameters
html
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,TValue>>

An expression that identifies the object that contains the properties to display.

additionalViewData
Object Object Object

An anonymous object that can contain additional view data that will be merged into the ViewDataDictionary<TModel> instance that is created for the template.

Returns

An HTML input element for each property in the object that is represented by the expression.

EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>) EditorFor<TModel,TValue>(HtmlHelper<TModel>, Expression<Func<TModel,TValue>>)

Returns an HTML input element for each property in the object that is represented by the Expression expression.

public static System.Web.Mvc.MvcHtmlString EditorFor<TModel,TValue> (this System.Web.Mvc.HtmlHelper<TModel> html, System.Linq.Expressions.Expression<Func<TModel,TValue>> expression);
static member EditorFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, 'Value>> -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function EditorFor(Of TModel, TValue) (html As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, TValue))) As MvcHtmlString
Type Parameters
TModel

The type of the model.

TValue

The type of the value.

Parameters
html
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,TValue>>

An expression that identifies the object that contains the properties to display.

Returns

An HTML input element for each property in the object that is represented by the expression.

Applies to