Page 1 of 1
FastReport: PDF export
Posted:
Mon Sep 16, 2013 3:30 pm
by Marco Turco
Hi all,
I'm succesfully using Fastreport (spirin class) for my FWH apps.
I need to provide my customers a function to export in PDF just some pages of the report.
I know the method FrPrn:SetProperty("RTFExport","FileName",cfile) but it exports all the report, not single pages.
Any ideas ? Thanks in advance.
Re: FastReport: PDF export
Posted:
Mon Sep 16, 2013 3:55 pm
by James Bott
This is not a good solution but maybe you can create a new report that only shows the pages you want exported to the PDF.
Re: FastReport: PDF export
Posted:
Mon Sep 16, 2013 4:55 pm
by Marco Turco
Hi James,
it's a bit complex that way.
I checked it is easy to generate an image file for each report page.
Do you know if there is a way to generate a PDF file from FW adding tiff or jpg files ?
Re: FastReport: PDF export
Posted:
Mon Sep 16, 2013 5:14 pm
by nageswaragunupudi
Re: FastReport: PDF export
Posted:
Mon Sep 16, 2013 8:43 pm
by Marco Turco
Solved, thank you for the suggest Rao.
Re: FastReport: PDF export
Posted:
Mon Sep 16, 2013 9:18 pm
by Otto
Marco, would you be so kind to post how.
Thanks in advance
Otto
Re: FastReport: PDF export
Posted:
Tue Sep 17, 2013 7:55 am
by Marco Turco
Hi Otto,
I had a single FRH report with multiple letters inside.
My target was to estract each letter from the report, convert it in a PDF document and send each via email to the recipient.
To do this I have found the following solution:
- using the method oFRH:Calc("Page#") and adding 1 when each letter is added to the report I know which is the report page number where the letter start
- when the report is complete I export it in jpg using the jpeg export method. This method automatically create multiple jpg files with the page number (example tmp.1.jpg,tmp.2.jpg...)
- due the fact I know which is the starting page no. for each letter I also know which is the name of the jpg files related, so using the FWPDF class as Rao suggested I can create a PDF merging the jpg related to the single letters.
Re: FastReport: PDF export
Posted:
Wed Sep 18, 2013 12:46 pm
by nageswaragunupudi
We introduced a new function
FWJPGTOPDF( aJpgFiles, cPdf )
in FWH13.08 revised build now available for download.