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

Kendo Chart - Get object of active chart

1 Answer 106 Views
Charts
This is a migrated thread and some comments may be shown as answers.
Jineesh
Top achievements
Rank 2
Jineesh asked on 09 Nov 2012, 09:51 AM
Hi,

     I have three chart with different ids in a page. At a time only one chart will be enabled and others are disabled.
     My requirement is how to get the clientside object of enabled chart. Chart has created using the kendo helper class.
     Please help me how to solve this issue.

1 Answer, 1 is accepted

Sort by
0
Alexander Valchev
Telerik team
answered on 14 Nov 2012, 08:52 AM
Hello Jineesh,

The widget client object is preserved in the jQuery data store for the corresponding element. In order to get the client side object of the chart you should select the corresponding element via jQuery selector and use the following code:
$("<chart element selector>").data("kendoChart");

At a time only one chart will be enabled and others are disabled. My requirement is how to get the clientside object of enabled chart.

Could you please specify how do you disable/enable the charts? In general if you attach a class "enabled" to the enabled chart you will be able to use a class selector: $(".k-chart.enabled")

Regards,
Alexander Valchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Charts
Asked by
Jineesh
Top achievements
Rank 2
Answers by
Alexander Valchev
Telerik team
Share this question
or