PDA

View Full Version : how to implementing chart event in controller to get the data of chart in extjs4.1



vijayakumar84
24 Apr 2013, 9:10 AM
Hi
can anybody tell how to implementing chart item click event in controller to get the data value of chart in extjs4.1.If user clicked bar need to get corresponding value of data value in controller


Thanks

slemmon
25 Apr 2013, 9:10 PM
The series has itemclick events amongst others that you can use to get the record from.
http://docs.sencha.com/extjs/4.2.0/#!/api/Ext.chart.series.Series

The event handler is passed an object with one of the properties being storeItem which will be the record for the item.

That said, the series is not a component so you can't listen to it directly with the controller. You'd need to do something like relayEvents with the series' chart.