InputExtensions.CheckBoxFor InputExtensions.CheckBoxFor InputExtensions.CheckBoxFor Method

Definition

Overloads

CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>)

Returns a check box input element for each property in the object that is represented by the specified expression.

CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, IDictionary<String,Object>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, IDictionary<String,Object>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, IDictionary<String,Object>)

Returns a check box input element for each property in the object that is represented by the specified expression, using the specified HTML attributes.

CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, Object) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, Object) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, Object)

Returns a check box input element for each property in the object that is represented by the specified expression, using the specified HTML attributes.

CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>)

Returns a check box input element for each property in the object that is represented by the specified expression.

public static System.Web.Mvc.MvcHtmlString CheckBoxFor<TModel> (this System.Web.Mvc.HtmlHelper<TModel> htmlHelper, System.Linq.Expressions.Expression<Func<TModel,bool>> expression);
static member CheckBoxFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, bool>> -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function CheckBoxFor(Of TModel) (htmlHelper As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, Boolean))) As MvcHtmlString

Type Parameters

TModel

The type of the model.

Parameters

htmlHelper
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,Boolean>>

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

Returns

An HTML input element whose type attribute is set to "checkbox" for each property in the object that is represented by the specified expression.

Exceptions

CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, IDictionary<String,Object>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, IDictionary<String,Object>) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, IDictionary<String,Object>)

Returns a check box input element for each property in the object that is represented by the specified expression, using the specified HTML attributes.

public static System.Web.Mvc.MvcHtmlString CheckBoxFor<TModel> (this System.Web.Mvc.HtmlHelper<TModel> htmlHelper, System.Linq.Expressions.Expression<Func<TModel,bool>> expression, System.Collections.Generic.IDictionary<string,object> htmlAttributes);
static member CheckBoxFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, bool>> * System.Collections.Generic.IDictionary<string, obj> -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function CheckBoxFor(Of TModel) (htmlHelper As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, Boolean)), htmlAttributes As IDictionary(Of String, Object)) As MvcHtmlString

Type Parameters

TModel

The type of the model.

Parameters

htmlHelper
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,Boolean>>

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

htmlAttributes
IDictionary<String,Object>

A dictionary that contains the HTML attributes to set for the element.

Returns

An HTML input element whose type attribute is set to "checkbox" for each property in the object that is represented by the specified expression, using the specified HTML attributes.

Exceptions

CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, Object) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, Object) CheckBoxFor<TModel>(HtmlHelper<TModel>, Expression<Func<TModel,Boolean>>, Object)

Returns a check box input element for each property in the object that is represented by the specified expression, using the specified HTML attributes.

public static System.Web.Mvc.MvcHtmlString CheckBoxFor<TModel> (this System.Web.Mvc.HtmlHelper<TModel> htmlHelper, System.Linq.Expressions.Expression<Func<TModel,bool>> expression, object htmlAttributes);
static member CheckBoxFor : System.Web.Mvc.HtmlHelper<'Model> * System.Linq.Expressions.Expression<Func<'Model, bool>> * obj -> System.Web.Mvc.MvcHtmlString
<Extension()>
Public Function CheckBoxFor(Of TModel) (htmlHelper As HtmlHelper(Of TModel), expression As Expression(Of Func(Of TModel, Boolean)), htmlAttributes As Object) As MvcHtmlString

Type Parameters

TModel

The type of the model.

Parameters

htmlHelper
HtmlHelper<TModel> HtmlHelper<TModel> HtmlHelper<TModel>

The HTML helper instance that this method extends.

expression
Expression<Func<TModel,Boolean>>

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

htmlAttributes
Object Object Object

An object that contains the HTML attributes to set for the element.

Returns

An HTML input element whose type attribute is set to "checkbox" for each property in the object that is represented by the specified expression, using the specified HTML attributes.

Exceptions

Applies to