Can I generate and email reports using a console app
Hi All,
I have a requirement to automate the emailing of some statistical reports on
a weekly basis from various offices to managers at a central head office.
For other things of this nature (but without the reporting/emailing
functionality) I would usually provide a console application which can then
be easily started by task scheduler.
Is it possible to load a template, generate the report and email it as a PDF
attachment from within a console app?
Thanks in advance.
Regards, Paul.
I have a requirement to automate the emailing of some statistical reports on
a weekly basis from various offices to managers at a central head office.
For other things of this nature (but without the reporting/emailing
functionality) I would usually provide a console application which can then
be easily started by task scheduler.
Is it possible to load a template, generate the report and email it as a PDF
attachment from within a console app?
Thanks in advance.
Regards, Paul.
This discussion has been closed.
Comments
I apologize for the late response.
Yes it is possible to create, manage, and print/email a report from a consol
application. You will probably need to disable all form displays before
printing (i.e. Print Dialog, Cancel Dialog, etc.). All of the report objects
and properties will need to be set in code as well. Take a look at the
Report.SendMail topic in the RB Help for how to send mail at runtime. Also
the following rbWiki section gives some good code examples.
http://www.digital-metaphors.com/rbWiki/Output/Email
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com