How to send attached Email through Progress/Syteline6.01

rajeshatl

New Member
Hi all,

I want to send attached emails through progress.Is it possible???
Please post the source code for the same..
 

bjprogtalk

New Member
Rajesh,

We are currently using netmailbot to handle e-mails from the Progress system.

You can download this through several sources on a trial basis. It is then about $130 US to purchase.

Essentially we use Progress to call the netmailbot executable. We then pass several paramaters and information to the netmailbot program and allow it to do the sending on progress's behalf. This works very well for us as we do not have to worry about mail clients or hardcoding any windows related code in our progress program.

Here is a very simplistic example of the progress code we use.

ASSIGN
MailDist = "jake@yourcompany.com jesse@yourcompany.com"

tOutLine = "@Echo off".
MESSAGE tOutLine.
tOutLine = '\\yoursrv\rpt-distro\netmailbot.exe -to ' + MailDist + ' -from reports@yourcompany.com -server YOURMAILSERVER -subject "DAILY INVOICE REPORT" -body "Please review the attached Daily Invoice Report." -attachment ' + '"' + \\yoursrv\rpt-distro\arinvoice\090808inv.csv + '"'.

MESSAGE tOutLine.
OUTPUT CLOSE.

Progress is of course creating the .CSV file through another automated process further up in the program. You may need to tweak this a little bit to get it to work in your environment. Also, we use some procedures further up in the program to create log files etc... In this instance, I have removed a couple of lines of code that also call a batch file that e-mails the log files as well. The batch file is essentially doing the same thing as above, only through the windows environment as the batch file is converting the log to a .pdf.
 
Top