The Batch mode is useful when you have multiple charts on a page and you want to export all of them together by calling a JavaScript API. The exported files for each chart can either be saved individually, or all the exported charts can be saved as a single file.

The export process in Batch Mode can be visualized as under:

Elements involved

For enabling export of chart in Batch mode, we will need to assemble the following elements:

  • The chart itself embedded using FusionCharts JavaScript class (FusionCharts.js). Here, we assume that you have been able to generate the chart for your page. If not, please refer to the relevant section of our documentation.
  • FusionCharts Export Component - This is named FCExporter.swf and is present in Download Package > Charts. You need to copy-paste this SWF to your server. A good location will be to place this SWF along with your chart SWFs.
  • FusionCharts Export Component JavaScript class - This JavaScript class is named FusionChartsExportComponent.js and is present in Download Package > Charts folder. Place it where you have placed FusionCharts.js on your website (though not necessary, but this helps you centralize all FusionCharts XT related JS files)

So let us quickly get started and setup a simple example that does Batch processing.