can't update Title!

7 posts, 1 answers
  1. Gerry
    Gerry avatar
    30 posts
    Member since:
    May 2017

    Posted 24 Oct 2018 Link to this post

    Why doesn't this work? 

    $('#my-kendo-numerictextbox').attr('title', '100');

    Currently the title/tooltip is displaying the value the is already visible in the textbox - seriously? 

    I want to be able to change the value dynamically to reflect the upper value allowed in the numeric textbox, in other words, some useful information.I'm a bit weird that way, wanting to show the users something that is actually useful...

    thanks

  2. Gerry
    Gerry avatar
    30 posts
    Member since:
    May 2017

    Posted 24 Oct 2018 Link to this post

    Please note my maximum values are dynamic, and change according to other choices in the UI.
  3. Answer
    Viktor Tachev
    Admin
    Viktor Tachev avatar
    2466 posts

    Posted 26 Oct 2018 Link to this post

    Hello Gerry,

    The NumericTextBox component renders two input elements internally. Thus, when changing the title attribute it should be applied to the input holding the formatted value. 

    Check out the example below that illustrates the approach.



    Regards,
    Viktor Tachev
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  4. Gerry
    Gerry avatar
    30 posts
    Member since:
    May 2017

    Posted 26 Oct 2018 in reply to Viktor Tachev Link to this post

    Thanks that works!

    Another solution (just discovered): add a class and use the class selector:

    $('.mykendonumerictextboxclassname').attr('title', '100');

  5. Viktor Tachev
    Admin
    Viktor Tachev avatar
    2466 posts

    Posted 30 Oct 2018 Link to this post

    Hello Gerry,

    The approach you describe is also an option. Thank you for sharing it with the community.


    Regards,
    Viktor Tachev
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  6. Jose Manuel
    Jose Manuel avatar
    2 posts
    Member since:
    Jun 2011

    Posted 05 Mar Link to this post

    Hello,

    I have tried this approach but when the value changes in the numeric textbox the title comes back again, so I have removed the attribute into the event "change" and it's working for me.

    $("#numerictextbox").kendoNumericTextBox({
        change: function(e) {
              e.sender.wrapper.find(".k-formatted-value").attr("title", "");
        }
    });

  7. Jose Manuel
    Jose Manuel avatar
    2 posts
    Member since:
    Jun 2011

    Posted 11 Mar Link to this post

    Hello,

    I have created a feature request in order to include it in next releases.Please, vote it if you like it.

    https://feedback.telerik.com/kendo-jquery-ui/1457415-allow-numerictextbox-to-have-no-title

Back to Top