You must be logged in to post your query.
Home › Forums › Chart Support › Create a chart everytime press the button
Tagged: #morechart
Hi everyone! I have a input field for JSON link and a button to create chart. Everytime I press the button, it will create a chart. When I change the JSON link and press the button again, it delete my old chart and create a new chart but I want it to create one more chart on the same page. How can I do that? Can you help me. Thank you very much!
@murcie96,
You can achieve the above requirement by creating a new div dynamically every time you pass a new JSON API link and render the chart using the provided JSON data source as shown in this JSFiddle.
Please use the following JSON data sources with the above example: https://api.myjson.com/bins/espz0 https://api.myjson.com/bins/vguws https://api.myjson.com/bins/166nss
____ Shashi Ranjan Team CanvasJS
You must be logged in to reply to this topic. Login/Register