I need the name of series when I clicked in any stacked column chart below is the code:
series=chart.column(thirdSeriesData);
setupSeriesLabels(series, "Requirements Complete");
series.fill("green");
series.listen("pointClick", function (e) {
console.log(e.iterator.get("value"));
console.log(e.iterator.get("name"));
console.log(e.iterator.get("x"));
});
note: when I click I am getting value and index and series name is undefined but I also want the series name here 'requirements complete' is my series how I will do it?
If you are applying series name using
name()
function, then you can get the series name from the event object in the same listener. For details, check the sample and pay attention to lines 17 and 32-36.