This is a migrated thread and some comments may be shown as answers.

How to add a ToolTip to a disabled button

1 Answer 1559 Views
ToolTip
This is a migrated thread and some comments may be shown as answers.
Grant
Top achievements
Rank 3
Iron
Iron
Veteran
Grant asked on 15 Jul 2019, 08:03 AM

Hi, 

AS my title says, how do I add a tooltip to a disabled kendoButton, for the purpose of telling a user why its disabled.

Dojo: https://dojo.telerik.com/OTOpIrOV

Thanks, 

Grant

1 Answer, 1 is accepted

Sort by
0
Martin
Telerik team
answered on 16 Jul 2019, 01:35 PM
Hello Grant,

Thank you for contacting us. Normally the browser does not execute mouseenter events for disabled elements. A possible approach to add the tooltip would be to place the button in a wrapper (e.g span) which has a title attribute:
<span title="This is a tooltip">
  <button data-role="button" data-enable="false" class="myTest">button</button>
</span>

This approach would work just fine without the Kendo Tooltip. Here is the modified version of your Dojo.

And here is another workaround using the widget. Again, you need to use a wrapper so that you can initialize the widget from it, and not from the button. Here is a Dojo example demonstrating it.

Feel free to contact us if you have further questions

Regards,
Martin
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.
Tags
ToolTip
Asked by
Grant
Top achievements
Rank 3
Iron
Iron
Veteran
Answers by
Martin
Telerik team
Share this question
or