NumericTextBox enable on init not working

4 posts, 0 answers
  1. Ben
    Ben avatar
    3 posts
    Member since:
    Apr 2013

    Posted 25 Jun 2014 Link to this post

    When creating a numeric text box with the option enable: false, the numeric text box is not disabled.
    This should work according to the documentation example:

    <script>
    $("#numerictextbox").kendoNumericTextBox({
    enable: false
    });

    var numerictextbox = $("#numerictextbox").data("kendoNumericTextBox");
    numerictextbox.enable(true);
    </script>

    http://plnkr.co/edit/tfsrw5ajeQh1nzTBFolr

    Does anybody have an idea what the issue could be?
  2. Georgi Krustev
    Admin
    Georgi Krustev avatar
    3707 posts

    Posted 25 Jun 2014 Link to this post

    Hello Ben,

    The NumericTextBox does not support enable configuration option, as it can be seen in API documentation. If you would like to disable widget on init, then just add disabled attribute to the original input element:
    <input id="numerictextbox" disabled />
    <script>
    $("#numerictextbox").kendoNumericTextBox();
    </script>

    Regards,
    Georgi Krustev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Kendo UI is VS 2017 Ready
  4. Ben
    Ben avatar
    3 posts
    Member since:
    Apr 2013

    Posted 25 Jun 2014 in reply to Georgi Krustev Link to this post

    Hi Georgi,

    That's what I thought, but in the example for the 'enable' method it clearly states that the options is passed as false and then enabled via the method.  So that is wrong and misleading in the example.

    http://docs.telerik.com/kendo-ui/api/web/numerictextbox#methods-enable

    Regards,
    Ben
  5. Georgi Krustev
    Admin
    Georgi Krustev avatar
    3707 posts

    Posted 25 Jun 2014 Link to this post

    Hi Ben,

    Yes, you are absolutely right. We will address the issue right away. Thanks for noticing it.

    Regards,
    Georgi Krustev
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
Back to Top
Kendo UI is VS 2017 Ready