Home › forums › Using CanvasJS › How to get graph type after chart is rendered
This topic contains 7 replies, has 2 voices, and was last updated by Akhil H 4 months, 2 weeks ago.
Is it possible to get the current type of graph after the graph is created using jquery
Yes, to get the chart type of first dataSeries use
Source: jQuery Integration Overview
I tried this code but it shows an error message ‘undefined is not a function’
I used chrome devtools console and came to know that CanvasJSChart() function is not available.
Without looking into code it’s hard to guess the issue. Can you please create a jsfiddle?
Here is the link
In canvasjs.min.js or canvasjs.js all chart initialized variables can be reffered using chart.options. So, here you can use chart.options.data.type to get assigned chart type of first dataSeries.
Thanks a lot
It worked fine…..
You must be logged in to reply to this topic.
ASP.NET MVC Charts
ContactSales EnquiriesSupport ForumTwitter Support Handle