kayrah87

SmartLabelManager.js Invalid Argument in Edge

Recommended Posts

Hi,

I'm using Fusioncharts in a business environment and I am having issues with charts not rendering at all on Edge and IE11.

The error I get is 'Invalid Argument' at position 2783 of minified SmartLabelManager.js

Any help would be appreciated. The code we are using is below:

window.addEventListener('DOMContentLoaded', function() {

            FusionCharts.render({
              type: 'StackedColumn2D',
              width: '450',
              height: '400',
              dataFormat: 'json',
              renderAt: 'stacked',
              dataSource: {
                chart: {
                  caption: 'Stacked Chart',
                  subCaption: 'Subtitle: Optional here',
                  xAxisname: 'X-Axis Label',
                  yAxisName: 'Y-Axis Label',
                  theme: 'marvin'
                },
                categories: [
                  {
                    category: [
                      {label: 'Jan'},
                      {label: 'Feb'},
                      {label: 'Mar'},
                      {label: 'Apr'},
                      {label: 'May'},
                      {label: 'Jun'}
                    ]
                  }
                ],
                dataset: [
                  {
                    seriesname: 'Legend 1',
                    data: [
                      {value: 500},
                      {value: 400},
                      {value: 300},
                      {value: 400},
                      {value: 900},
                      {value: 550}
                    ]
                  },
                  {
                    seriesname: 'Legend 2',
                    data: [
                      {value: 950},
                      {value: 700},
                      {value: 550},
                      {value: 400},
                      {value: 300},
                      {value: 650}
                    ]
                  },
                  {
                    seriesname: 'Legend 3',
                    data: [
                      {value: 600},
                      {value: 400},
                      {value: 800},
                      {value: 400},
                      {value: 550},
                      {value: 300}
                    ]
                  }
                ]
              }
            });

            // Render
            //chartInstance.render();
          });
       

Thanks

Edited by kayrah87
typo in title

Share this post


Link to post
Share on other sites

Hi,

 

FusionCharts "ready" static method allows you to register callback functions that are executed when the FusionCharts library is ready to be used. In general, the FusionCharts framework is ready after the DOMContentLoaded browser event has been triggered and all the initial dependent files/modules are available.

So, it is recommended that all entry-point and initialization codes are written within the ready()function. Please refer to the sample fiddle : http://jsfiddle.net/9nzjdaeo/2/

For reference you can check the documentation link for the "ready()" API method : https://www.fusioncharts.com/dev/api/fusioncharts/fusioncharts-methods

 

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