You must be logged in to post your query.
Home › Forums › Chart Support › call methods
hello how can i call canvas methods like this
document.getElementById(‘id’).canvasmethod()
?
@mat,
Please refer to this tutorial for a complete list of methods and properties on canvas.
— Shashi Ranjan Team CanvasJS
thanks . I want to know how can i call canvas.js methods like this.
for example lets say render method.
document.getElementById(‘mychart’).render()
or lets say set method
document.getElementById(‘mychart’).set(“zoomEnabled”, true);
The document.getElementById() method returns the HTML DOM element that has the ID attribute with the specified value. To access the methods and properties of the chart, you will have to use its reference(e.g chart.render()). Please refer to this documentation page for more information on accessing the methods and properties of the chart.
You must be logged in to reply to this topic. Login/Register