Report.SendMail
Hi there!
I want to decide within a report whether it will be sent as email or to a
printer but i get an error when i attempt to compile this code.
It seems that the Report.SendMail is not available with RAP. Is this
correct,and is there a way round this?
See code below.
Best regards,
Terje Syversen
procedure GroupHeaderBand3BeforePrint;
begin
if (Business['bu_confirmtype']='EPost') AND (Business['bu_email'] <> '')
then
begin
Report.EmailSettings.FileName :=
FormatDateTime('ddmmyy_hhmmsss',CurrentDate)+'.pdf';
Report.EmailSettings.Recipients.Add(Business['bu_email']);
Report.EmailSettings.CarbonCopy.Add('terje@pcp.no');
Report.EmailSettings.Body.Add('Bookingbekreftelse fra Idre-fj?ll');
Report.EmailSettings.Body.Add('Hei p? deg '+Business['bu_name']);
Report.EmailSettings.Body.Add('Se detaljer i vedlegg! ');
Report.SendMail;
end;
end;
I want to decide within a report whether it will be sent as email or to a
printer but i get an error when i attempt to compile this code.
It seems that the Report.SendMail is not available with RAP. Is this
correct,and is there a way round this?
See code below.
Best regards,
Terje Syversen
procedure GroupHeaderBand3BeforePrint;
begin
if (Business['bu_confirmtype']='EPost') AND (Business['bu_email'] <> '')
then
begin
Report.EmailSettings.FileName :=
FormatDateTime('ddmmyy_hhmmsss',CurrentDate)+'.pdf';
Report.EmailSettings.Recipients.Add(Business['bu_email']);
Report.EmailSettings.CarbonCopy.Add('terje@pcp.no');
Report.EmailSettings.Body.Add('Bookingbekreftelse fra Idre-fj?ll');
Report.EmailSettings.Body.Add('Hei p? deg '+Business['bu_name']);
Report.EmailSettings.Body.Add('Se detaljer i vedlegg! ');
Report.SendMail;
end;
end;
This discussion has been closed.
Comments
send a small email to support@digital-metaphors.com if you would like the
patch.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com