setOptions

Allows changing the widget configuration after initialization. Depending on the widget, some properties may not be changed, and the method's implementation varies for each widget.

In some cases, the setOptions method can recreate and rebind the widget instance. Calling setOptions in an event handler or the respective widget is not recommended and can cause an endless loop or a JavaScript error.

Parameters

newOptions Object

The options to be changed or added.

Example - use setOptions to change the maximum value of a NumericTextBox

<input type="number" id="ntb" value="1" />

<script>

$(function(){
    $("#ntb").kendoNumericTextBox({
        max: 5
    });

    // ...

    $("#ntb").data("kendoNumericTextBox").setOptions({
        max: 10
    });
});

</script>
In this article