Exporting Service

Description

Export Chart as PNG, JPG, SVG, PDF document, Excel document or Word document.

URL

window.baseurl+’/api/JSChartExport/ExportChart’

Parameters

Name Value
exportMultipleChart false

Request

  • js
  • var chart = $(".e-datavisualization-chart").ejChart("instance");
    var exportSettings = chart.model.exportSettings;
    exportSettings.fileName = "Chart";
    exportSettings.angle = "90";
    exportSettings.type = "png";
    exportSettings.mode = 'server';
    exportSettings.action = window.baseurl+'api/JSChartExport/ExportChart';
    data = chart.export();

    Response (PNG, JPG, SVG, PDF, Word or Excel):

    Status Code: 200

    Content-Type: application/octet-stream

    Browser will prompt a dialog box to save the file (image or document).