shape tooltip - ajax

2 posts, 1 answers
  1. Justin Lee
    Justin Lee avatar
    164 posts
    Member since:
    Dec 2009

    Posted 12 Jul Link to this post

    Hello,

    I connected a kendo tooltip to my diagram with a filter of "g".  The tooltip is showing when hovering over a shape. I want the tooltip to be loaded from ajax, so I have added an event handler for requestStart of the tooltip.

    However, I cannot seem to access the dataItem of the shape in the requestStart event handler to get the id of the item.  e.target[0] appears to be the shape, but I can't seem to access the dataItem from it.

    Let me know if you want any sample code.

    Thanks.

  2. Answer
    Tsvetina
    Admin
    Tsvetina avatar
    2085 posts

    Posted 14 Jul Link to this post

    Hi Justin,

    You should be able to access the shape JavaScript object by following a similar approach to the one used in this sample:
    Drag and Drop on Existing Shapes

    You can see the code in the DropTarget's drop event handler, where a Shape is obtained using event page coordinates. Once you have a reference to the Shape object, you can get the dataItem. If you have problems with accessing the needed values, you can send me a Dojo, where I can get to the point where you need to fire the request with parameters.

    Regards,
    Tsvetina
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top