Home forums Using CanvasJS Export Multiple chart in one pdf

This topic contains 3 replies, has 3 voices, and was last updated by  Vishwas R 4 months, 3 weeks ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #22345

    Its working fine when 3 charts . its exports correctly.
    but if more than 5 charts pdf size will change but chart not show in pdf.

    #22347

    @otaindia,

    We don’t have exporting chart as pdf, as of now. But with couple of lines of code you can export to pdf using jsPDF as shown in this jsfiddle.

    Using html2canvas along with jspdf, you can achieve exporting multiple charts. Refer this jsfiddle for the same.

    Exporting more than 5 charts also seems to be working fine, when you configure html2canvas options accordingly. Please take a look at this updated jsfiddle. Please refer html2canvas documentation for more configuration options available and configure it in your webpage / app accordingly.


    Vishwas R
    Team CanvasJS

    #24490

    I need to export multiple charts from a single page. Exporting first chart is ok but when I try to export 2nd chart, the chart exports successfully but the chart rendered in PDF from the x-coordinate(say 400px of the window) where the width of first chart was ended because of which half of the second chart is hidden. Could you please suggest me to solve this issue. Might be we need to refresh html2canvas?

    Regards,
    Samyukta

    #24497

    Samyukta,

    Exporting multiple charts (morethan 5) also seems to be working fine – charts are positioned vertically and not one next to other. Can you kindly share JSFiddle reproducing the issue you are facing so that we can look into your code, understand it better and help you out?

    Also refer documentation of jsPDF and html2canvas for more available options like offsets / position of an element while exporting DOM as PDF.


    Vishwas R
    Team CanvasJS

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.