Recommended Posts

I am trying to create a multi-series column chart in our application. The error I am getting is - "Cannot read property 'category' of undefined"

I tried to recreate the issue in jsfiddle (https://jsfiddle.net/Apeksha82/j092Lewy/13/) before creating a topic here, but I get a different error there - "FusionCharts is not defined". I am comparing mine with your jsfiddle here - http://jsfiddle.net/fusioncharts/ppcas1oo/, but can't see what is wrong. I have included the required references.

Could you please take a look at the jsfiddle error? 

 

Share this post


Link to post
Share on other sites

Hi,

 

The categories is an array of objects as per the prescribed dataSource format of mscolumn2d chart type of FusionCharts. In your implementation, it is defined as an object, hence you are getting the error.

Please find the below modified fiddle working with your implementation : https://jsfiddle.net/fb2awdy3/

For further reference, please check the documentation link for the dataSource structure : https://www.fusioncharts.com/dev/chart-guide/standard-charts/multi-series-charts

 

Thanks,

Akash

Share this post


Link to post
Share on other sites

Thanks, that was it!

Also want to confirm that the mscolumn2d doesn't have a version with scrolling x-axis. I couldn't find anything in your documentation. 

Share this post


Link to post
Share on other sites

Hi,

 

You can use the "scrollcolumn2d" chart type for rendering a column chart with x-axis scroll. In your implementation it could be achieved by changing the chart type to "scrollcolumn2d" along with few additional attributes like "numVisiblePlot" supported for scroll charts.

Sample fiddle : https://jsfiddle.net/64hvrb8g/

Please note : Scroll charts are multi-series in nature, and has the same dataSource structure like a multi-series chart.

For further reference, please check the documentation of Scroll charts : https://www.fusioncharts.com/dev/chart-guide/standard-charts/scroll-charts

 

Thanks,

Akash.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now