Clear or Destroy Kendo Tooltip

7.4k Views Asked by At

I am unable to clear kendo tooltip. My code is as follows:

var tooltip = $("#DIV_ID").kendoTooltip();
tooltip.hide();

I also tried destroy event but tooltip is not getting cleared properly.

I have added an image for how tooltip appears after clearing it.

1

There are 1 best solutions below

0
On

In order to invoke the method hide of kendoTooltip you should do:

tooltip.data("kendoTooltip").hide();

What you do with tooltip.hide(); is hiding the HTML element associated to the tooltip.

In order to destroy the tooltip, you should do:

tooltip.data("kendoTooltip").destroy();

Check the following example: http://jsfiddle.net/OnaBai/f5g7C/

  1. when clicking on Hide tooltip you hide the tooltip (but it will show again when the mouse is over)
  2. when clicking on Hide DIV you hide the DIV associated to the tooltip
  3. when clicking on Destroy tooltip you destroy the tooltip