You must be logged in to post your query.
Home › Forums › Chart Support › chart.render() not working
Tagged: chart render
I am trying to run following canvas JS code, and new to Canvas JS
alert(“inside before onload function ()”); window.onload = function () { alert(“start function ()”);
var chart = new CanvasJS.Chart(“chartContainer”, { title: {
text: “Column Chart in JSP using CanvasJS” },
data: [ { type: “column”, dataPoints: [ { label: “DCS”, y: 10 }, { label: “WXM”, y: 15 }, { label: “CCM”, y: 25 }, { label: “Archival”, y: 30 }, { label: “Total”, y: 28 } ] } ] }); alert(“before chart render”); chart.render(); alert(“after chart render”);
}
not displaying chart after alert of start function() onload. not getting any error also on console..
When i inspect the page – i get following error
Uncaught ReferenceError: CanvasJS is not defined.
You have included the SCRIPT?
Thank you
You must be logged in to reply to this topic. Login/Register