New to Kendo UI for jQuery? Start a free 30-day trial

Exports the chart as an image.

Inherited from Chart.exportImage

Parameters:options.widthString

Parameters for the exported image.

options.heightString

The width of the exported image. Defaults to the chart width.

Returns:Promise

A promise that will be resolved with a PNG image encoded as a Data URI.

<div id="sparkline"></div>
<script>
var sparkline = $("#sparkline").kendoSparkline({
    type: "column",
    series: [{
        data: [10, 15, 8, 12]
    }]
}).data("kendoSparkline");

sparkline.exportImage().then(function(dataURI) {
    // Display the exported image or save it
    console.log(dataURI);
});
</script>
Not finding the help you need?
Contact Support