enable

Enables or disables the SplitButton and all the items in the Button list.

Parameters

state Boolean

Indicates whether the SplitButton should be enabled or disabled. true and false arguments are accepted. If no argument is supplied, the SplitButton will assume true and will be enabled.

items String|jQuery

Collection of the items to disabled/enabled.

Example

Open In Dojo
<button id="splitbutton" type="button">Button</button>
<script>
    $("#splitbutton").kendoSplitButton({
        items:[
            { text: "item 1" },
            { text: "item 2" }
        ]
    });
    var button = $("#splitbutton").data("kendoSplitButton");
    // disable button
    button.enable(false);
</script>

Example - disable a specific item

Open In Dojo
<button id="splitbutton" type="button">Button</button>
<script>
    $("#splitbutton").kendoSplitButton({
        items:[
            { id: "item1", text: "Item 1" },
            { id: "item2", text: "Item 2" }
        ]
    });
    var button = $("#splitbutton").data("kendoSplitButton");

    button.enable(false, "#item1");
</script>

Example - disable a collection of items

Open In Dojo
<button id="splitbutton" type="button">Button</button>
<script>
    $("#splitbutton").kendoSplitButton({
        items:[
            { id: "item1", text: "Item 1" },
            { id: "item2", text: "Item 2" }
        ]
    });
    var button = $("#splitbutton").data("kendoSplitButton");

    button.enable(false, $("#item1, #item2"));
</script>
In this article