I am tiring to drill down twice and tiring to change the subtitle as I drill down.
plotOptions: {
column: {
cursor: 'pointer',
point: {
events: {
click: function(e) {
var drilldown = this.drilldown;
//var drilldownC = this.drilldown.categories;
if (drilldown) { // 1st drill down
this.series.chart.setTitle({
text: drilldown.name
});
chartC.setTitle(null, {
text: 'BBBBBBB'
});
} else {
chartC.setTitle({
text: name
});
chartC.setTitle(null, {
text: 'AAAAAA'
});
}
}
}
},
dataLabels: {
enabled: true,
formatter: function() {
return this.y;
}
}
}
},
I am tiring to do this but it not working:
plotOptions: {
column: {
cursor: 'pointer',
point: {
events: {
click: function(e) {
var drilldown = this.drilldown;
//var drilldownC = this.drilldown.categories;
if (drilldown) { // 1st drill down
this.series.chart.setTitle({
text: drilldown.name
});
chartC.setTitle(null, {
text: 'BBBBBBB'
});
----------
if (drilldown) {
this.series.chart.setTitle({
text: drilldown.name
});
chartC.setTitle(null, {
text: 'CCCCCCCC'
});
}
----------
} else {
chartC.setTitle({
text: name
});
chartC.setTitle(null, {
text: 'AAAAAA'
});
}
}
}
},
dataLabels: {
enabled: true,
formatter: function() {
return this.y;
}
}
}
},
all I did is added:
----------
if (drilldown) {
this.series.chart.setTitle({
text: drilldown.name
});
chartC.setTitle(null, {
text: 'BBBBBBB'
});
}
----------
if any one has a solution please let me know. all I needd to do is chaeck if "drilldown" exist?