CheckBoxGroupItemBuilder

Methods

HtmlAttributes(System.Collections.Generic.IDictionary)

Parameters

value - System.Collections.Generic.IDictionary<String,Object>

HtmlAttributes(System.Object)

Collection of key-value pairs that would be used to generate the attributes attached to each k-checkbox-item element.

Parameters

value - System.Object

The value for HtmlAttributes

RETURNS

Returns the current CheckBoxGroupItemBuilder instance.

CssClass(System.String)

Any custom classes that should be attached to the k-checkbox-item element.

Parameters

value - System.String

The value for CssClass

RETURNS

Returns the current CheckBoxGroupItemBuilder instance.

Example

Razor
 
            @( Html.Kendo().CheckBoxGroup()
                        .Name("CheckBoxGroup")
                        .Items(i =>
                        {
                            i.Add().Label("Spain").CssClass("spain").Value("1");
                            i.Add().Label("Italy").Value("2");
                            i.Add().Label("UK").Value("3");
                        })
            )
             

Enabled(System.Boolean)

Defines whether the checkbox is enabled or not. By default all checkboxes are enabled.

Parameters

value - System.Boolean

The value for Enabled

RETURNS

Returns the current CheckBoxGroupItemBuilder instance.

Example

Razor
 
            @( Html.Kendo().CheckBoxGroup()
                        .Name("CheckBoxGroup")
                        .Items(i =>
                        {
                            i.Add().Label("Spain").Enabled(false).Value("1");
                            i.Add().Label("Italy").Value("2");
                            i.Add().Label("UK").Value("3");
                        })
            )
             

Encoded(System.Boolean)

Determines whether the checkbox label content should be rendered as an HTML string or it should be encoded.

Parameters

value - System.Boolean

The value for Encoded

RETURNS

Returns the current CheckBoxGroupItemBuilder instance.

Example

Razor
 
            @( Html.Kendo().CheckBoxGroup()
                        .Name("CheckBoxGroup")
                        .Items(i =>
                        {
                            i.Add().Label("<strong>Spain</strong>").Encoded(false).Value("1");
                            i.Add().Label("Italy").Value("2");
                            i.Add().Label("UK").Value("3");
                        })
            )
             

Label(System.String)

Specifies the label content for the checkbox.

Parameters

value - System.String

The value for Label

RETURNS

Returns the current CheckBoxGroupItemBuilder instance.

Example

Razor
 
            @( Html.Kendo().CheckBoxGroup()
                        .Name("CheckBoxGroup")
                        .Items(i =>
                        {
                            i.Add().Label("Spain").Value("1");
                            i.Add().Label("Italy").Value("2");
                            i.Add().Label("UK").Value("3");
                        })
            )
             

Value(System.String)

Specifies the value for the checkbox.

Parameters

value - System.String

The value for Value

RETURNS

Returns the current CheckBoxGroupItemBuilder instance.

Example

Razor
 
            @( Html.Kendo().CheckBoxGroup()
                        .Name("CheckBoxGroup")
                        .Items(i =>
                        {
                            i.Add().Label("Spain").Value("1");
                            i.Add().Label("Italy").Value("2");
                            i.Add().Label("UK").Value("3");
                        })
            )