You are viewing documentation for an older version. For current documentation - click here.

When trying to make a chart using FusionWidgets XT, if you get any errors (or if the chart doesn't render), there could a lot of reasons for it. Here, we'll try and cover them up. We've divided the entire debugging process into various sections:

Let's get to basic trouble shooting first. While creating your chart, if for some reasons you do not see your chart like it should, check for the following actions:

If you do not see any chart at all

If you see an endless loading progress bar in your browser, or if the right click menu (right click at the place where the chart is supposed to be) shows "Movie not loaded", check the following:

  • Have you pasted the chart SWF and JavaScript files (FusionCharts.js, FusionCharts.HC.js, FusionCharts.HC.Widgets.js and jquery.min.js) in the required folder?
  • Have you provided the name and path of the chart properly in your code?
 
If you get a "Error in Loading Data." message, check the following:
 
  • Whether you've provided proper path to the XML/JSON data in your code.
  • Whether your XML/JSON file is named properly and not having a .txt extension (as many basic text editors append .txt after the file name).
  • If you're using an operating system that uses case-sensitive naming for file system (like mac, linux etc.), check for the names of your XML/JSON and chart file.
  • Whether your chart files (SWF and JavaScript) and XML/JSON data are on the same domain or same sub-domain. Cross domain data loading is not allowed.
 
If you get an "Invalid Data." message, it means that the XML/JSON data is malformed. Check it again for common errors like:
 
  • Presence of duplicate attributes in the XML/JSON.
  • Difference in case of tags. <chart> should end with </chart> and not </Chart> or </CHART>
  • Missing opening/closing quotation marks for any attributes. e.g., <chart numberSuffix=%' should be <chart numberSuffix='%'.
  • Missing closing tag for any element.
  • If you've double quotes as part of your data, XML Encode them to &quot; Example: <set label='John says &quot;Hi&quot; to all.' />
  • If you've single quotes as part of your data, XML Encode them to &apos; Example: <set label='John&apos; house' />
  • While using HTML embedding and Data String method, if you're using any special characters in your XML, make sure they're properly encoded. Like, % needs to be encoded as %25 & as %26. In Data URL method, you can provide most of the characters directly, without the need to encode.
  • While using HTML embedding and Data String method, check for conflict of ' (XML Attribute Character) and " (HTML Parameter Character). For example, if you're using " for HTML parameters, then you need to make sure that all your XML attributes use ' as containers. Example: <param name="FlashVars" value="<chart showLabels='1' showValues='1'>...</chart>" />
 
If you get a screen showing "The chart will appear within this DIV..." or "Chart." or "FusionWidgets XT will load here", check if:
 
  • You've copied FusionCharts.js, jquery.min.js, FusionCharts.HC.js and FusionCharts.HC.Widgets.js in the right folder.
  • You've included and provided the correct path of FusionCharts.js in your HTML code.
  • There are any JavaScript syntax or runtime errors that might have halted the execution of FusionCharts APIs.
  • Unique names are used for the chart's JavaScript variable, chart's ID and the HMTL DIV's ID?

    To provide cross-browser compatibility, we recommend you not to start the ID with a numerical value, nor use space as part of the ID.
 
"No data to display" message

If your chart shows a "No data to display" message, it could be the following scenarios:

  • Your XML/JSON data doesn't contain any data that could be plotted by a chart or gauge. In this case, your XML just contains the <chart></chart> without any data or you JSON just contains { "chart" : {} }.
  • You might be using a data format (XML/JSON) which is not supported by the chart/gauge which you want to render. For example, you are rendering a Real-time Line chart and providing it the XML/JSON data built for Angular gauge.
 
If you get a "... is not a function of ..." error when using any JavaScript API of the chart, make sure that:
 
  • Make sure that you're not calling the JavaScript method before the chart has loaded and rendered. You need to use FC_Rendered function or define event listener for Rendered event of chart to track the loading of chart as explained in the FusionWidgets XT and JavaScript section.
  • Make sure that you're NOT running the chart from local file system (C:\ , D:\). Instead, run the chart from behind a server (localhost - IIS, Apache etc.). This is because the Flash Player security settings do not allow the chart to interact with JavaScript on local file system by default, unless otherwise specifically set. Still if you want to run the chart from local file system, you need to set up the Flash Player Global Security settings. To know more on how to set up click here.