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

EmailSettings.ReportFormat

edited March 2006 in RAP
Hi,

Can I change Report.EmailSettings.ReportFormat with RAP?

I am using TExtraDevices and I want to change some reports to send in Excel
Format.

In which events should I change it?

I have put in the report component EmailSettings.ReportFormat = ExcelFile
(Delphi)

In RAP ReportBeforePrint event I put:
Report.EmailSettings.ReportFormat := 'PDF';

But in the email the attachment is an excel file.

Thanks,

Jose Maria Sanmartin

Comments

  • edited March 2006
    Hi Jose,

    If you are emailing from the preview window, you can use the
    Report.OnInitializeParameters event to change the ReportFormat property of
    the EmailSettings. Something like the following...

    procedure ReportOnInitializeParameters(var aCancel: Boolean);
    begin

    Report.EmailSettings.ReportFormat := 'PDF';
    aCancel := False;

    end;

    If you are calling Report.SendMail directly, you will need to change the
    ReportFormat before making this call in Delphi.

    --
    Regards,

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

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited March 2006
    Thanks,

    Jose Maria Sanmartin
This discussion has been closed.