Page 1 of 1

Save charts to an existing PDF

Posted: Tue Jun 18, 2019 1:25 pm
by 16583852
Hello,

How do I add a chart to an existing PDF using TeeSaveToPDFFile?

I want to create several charts, one at a time, and add them to the same PDF.

Thanks,

Dave

Re: Save charts to an existing PDF

Posted: Wed Jun 26, 2019 3:04 pm
by 16583852
Anyone have suggestions on how to do this? A different tool perhaps?

One of our customers wants the ability to export several graphs into the same PDF.

Thanks,

Dave

Re: Save charts to an existing PDF

Posted: Thu Jun 27, 2019 10:04 am
by yeray
Hello,

This sounds exactly as the feature request in the ticket #1473.
Feel free to add your mail to the CC list.

Re: Save charts to an existing PDF

Posted: Fri Jun 28, 2019 7:53 pm
by 16583852
Thanks Yeray.

It looks like this request goes back to 2016. Do you know if this Is a feature that is to be added soon? If not, I will look for another solution.

Dave

Re: Save charts to an existing PDF

Posted: Mon Jul 01, 2019 11:24 am
by yeray
Hello,

We've just added a new AddPanel function that allows you to add several charts to pdf to be created.
So, with the next release, it will be possible to do this:

Code: Select all

  with TPDFExportFormat.Create do
  try
    for i:=0 to High(Charts) do
      AddPanel(Charts[i]);

    SaveToFile(fileName);
  finally
    Free;
  end;
Here the resulting pdf:
Chart1.zip
(14.82 KiB) Downloaded 679 times

Re: Save charts to an existing PDF

Posted: Wed Jul 03, 2019 3:45 pm
by 16583852
Yeray,

Excellent! It works perfectly!

Thanks for all your help.

Dave

Re: Save charts to an existing PDF

Posted: Thu Jul 04, 2019 7:38 am
by yeray
Great! Thanks for the feedback!