@myezasifiso,
You can reset the chart range programmatically by setting the viewportMinimum and viewportMaximum of x-axis to null inside the rangeChanged event handler as shown in the code snippet below –
rangeChanged: function(e) {
if(e.trigger === "reset"){
e.chart.options.axisX[0].viewportMinimum = null;
e.chart.options.axisX[0].viewportMaximum = null;
e.chart.render();
}
},
Please take a look at this JSFiddle for complete working code.
___________
Indranil Deo
Team CanvasJS