We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

How to Print chart

Thread ID:

Created:

Updated:

Platform:

Replies:

131193 Jun 27,2017 11:49 AM Jun 28,2017 02:15 AM ASP.NET Core 1
loading
Tags: Chart
George Rossopoulos
Asked On June 27, 2017 11:49 AM

Hi

I wonder if there is an easy way to print the chart from javascript and not the whole web  page.

Thank you
George

Dharanidharan Dharmasivam [Syncfusion]
Replied On June 28, 2017 02:15 AM

Hi George, 

Thanks for contacting Syncfusion support. 

We have analyzed your query. We would like to let you know that we have provided support for printing the chart from Essential Studio version 15.2.0.40, so if you are using the lower version, you can upgrade to the current version from the below link. 


We have prepared a sample for printing the chart in a button click. In the print method you need to pass the id of the chart element which need to be exported. In the sample we have used the current version (15.2.0.43) minified web all file. Find the code snippet below to achieve your requirement. 

ASP.NET Core: 

<input type="button" onclick="printChart()" value="Print Chart" /> 
 
<ej-chart id="container" > </ej-chart> 
 
function printChart() { 
        var chart = $("#container").ejChart("instance"); 
        chart.print("container"); 
    } 


Screenshot: 
 

Sample for reference can be find from below link. 
 
For more information on printing, follow the below link. 

Thanks, 
Dharani. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;