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

new devices

edited May 2010 in General
Can you give me a code example for outputting to new devices? I have report
in preview and use a custom button to open a dialog prompting for output to
the various formats.

Need to know the best way to output to pdf, word, excel, etc at that point.

Comments

  • edited May 2010
    Hi Bob,

    We will be posting articles/examples on how to use these new features soon.
    I will post out here when they are available.

    --
    Regards,

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

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited May 2010

    The RBuilder help contains simple examples. Check out the help topics for
    TppPDFDevice, TppRTFDevice, TppXLSDataDevice, etc.

    Here are the basics...

    Use the constants defined in ppTypes.pas to specify the DeviceType and then
    call Print.

    Example:

    uses
    ppTypes;

    begin

    myReport.AllowPrintToFile := True;
    myReport.ShowPrintDialog := False; // hide the print dialog

    myReport.DeviceType := dtPDF; // output to PDF
    myReport.TextFileName := 'c:\MyReport.PDF';

    myReport.Print;

    end;


    --
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com



    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
  • edited May 2010
    I am curious about other options in the export device features. For
    example, when exporting to excel, will there be an option to export the
    entire field results of the query rather than just fields represented on the
    report in the design tab? Also, is there a way when exporting to excel
    data, to include column headings?

    Thanks,
    Bob

  • edited May 2010

    Here is some detailed information that I think answers your questions:

    http://www.digital-metaphors.com/rbWiki/General/What's_New/RB_12/Report_Output_Enhancements


    Also the RBuilder help topics for TppXLSDataDevice and TppXLSReportDevice
    are useful. The help topic for TppXLSSettings was omitted by mistake, we
    will add it for the next build. For now, you can open
    RBuilder\Source\ppXLSSettings.pas - the help text appears at the top of the
    unit.



    --
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.