- Jon Stoller
- PowerBuilder
- Sunday, 20 May 2018 06:58 PM UTC
Can I send email via Outlook from PowerBuilder?
Can I send it with an attachment?
How do I do it?
QUESTION:
I created a report in PowerBuilder and I want the Power Script to send a copy of it as an email attachment.
How is it done? Assume the required information is as follows:
String ls_folderfile, ls_email_addr, ls_subject, ls_email_text_message
//Do you need the sender's email address?
String ls_sender_addr
integer li_return
ls_folderfile = "c:\pdf\pbreport.pdf"
idw_rpt.Object.DataWindow.Export.PDF.Method = XSLFOP!
li_return = idw_rpt.SaveAs(ls_folderfile, PDF!, true)
ls_sender_addr = "jon@akaware.com"
ls_email_addr = "jonstoller56@gmail.com"
ls_subject = "Report from AKA Software"
ls_email_text_message = "The attachment is a report from AKA Software"
//What do I do next to send an email to the above email address, with the above subject and text message, with the above file attached (ls_folderfile).
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.