Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

How to save the report as PDF

edited April 2005 in General
How do I export the output of the report as PDF or other format in code ?

Comments

  • edited April 2005
    Hi,

    ReportBuilder 9 or higher includes built in support for the export to PDF.
    For help and examples, please see the "ppPDFDevice" topic in the
    RBuilder.hlp file and check out demos 108 and 109 located in the
    \RBuilder\Demos\1. Reports\... directory.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2005
    I am using version 7.03 and have installed the third party TExtraDevice.

    Now I can print the report to a file in PDF format.
    However, there is a pop up box showing the progress. How do I suppress or
    hide this progress box ?

  • edited May 2005
    TppReport.ShowCancelDialog := False;

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2005
    Thanks. Yes, it works.
    BTW, if my report has many pages, it may take a while to print as .pdf file,
    how do I know it is finished if I suppress the dialog ?

  • edited May 2005
    Hi,

    Well, that's what the cancel dialog is for :).

    The TppReport.AfterPrint event will fire when the report has finished
    exporting.

    There is a property in the TppReport.PDFSettings named OpenPDFFile that will
    automatically open the generated PDF file using your default viewer once it
    has finished. This could also be used to tell when the file is ready for
    viewing.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2005
    What I want to do is I will email the report as attachment after the export
    of the report:

    ppReport.Print;
    // do the email settings and attachment here
    ...
    ....
    // then do the Emailing here

    I am afraid of the Delphi statement of emailing will be executed before the
    report is actually finished exported.
    Will the ppReport.Print statement stay there before the whole report is
    exported ? Or continue executing statements while exporting ?

  • edited May 2005
    Hello,

    ReportBuilder will complete printing before any Delphi code after the
    Report.Print command is executed. The setup you describe below should work
    correctly.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2005
    I now can export the report as PDF but I found a strange thing in the
    exported PDF file is
    I put some labels in the summary band and assign strings to these labels,
    they did not show up in the exported PDF.

    BUT they do show up in the report if I preview by running my application.



  • edited May 2005
    Hello,

    This is not a known issue with the ReportBuilder PDF export feature. If you
    are using a third party export utility such as TExtraDevices, you will need
    to contact their support directly (support@waler.com). I believe
    TExtraDevices gives the ability to toggle the visibility of each type of
    report component when exported to PDF. Be sure all text components are
    enabled.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.