We automatically send CSV-formatted ASNs (Advance Ship Notices), but use the following to send them as an attachment that, to the user, appears to be an Excel spreadsheet. Some of the more informative lines would be:
027: MAIL.TO.EMAIL<1,1> = <mailto:'[EMAIL PROTECTED]'> '[EMAIL PROTECTED]' 028: MAIL.TO.NAME<1,1> = 'ASN List' 029: MAIL.SUBJECT = "ASN for ":OCONV(DATE(), "D2/") 030: MAIL.CONTENT.TYPE<1,1> = 'text/plain' 031: MAIL.HEADER.USE = 'DEFAULT-ONLY' 032: MAIL.MULTIPART = 'Y' 033: 034: * Send generated spreadsheet via email 035: MAIL.TEXT<1,1,1> = 'EDI ASN for ':OCONV(DATE(), "D2/") 036: MAIL.TEXT<1,1,1> := ". Please send any comments to [EMAIL PROTECTED]" 037: MAIL.TEXT<1,2> = '' 038: MAIL.CONTENT.TYPE<1,2> = 'application/vnd.ms-excel' 039: READV HOME.PATH FROM CONTROL,'HOMEPATH',1 ELSE 040: HOME.PATH = "/export/home/ftptrans" 041: END 042: MAIL.ATTACH.FILES<1,2> = HOME.PATH:'/':SPRDSHT.NAME We then call a generic subroutine, SEND.MIME.EMAIL, that attaches the generated CSV file and bangs directly on the mail server to send it out. Hope this helps. If you'd like more details, contact me off list and I'll be happy to answer questions. -- Dave Walker Programmer/Analyst Ivy Hill - Louisville (502) 473-2811 *IBM Certified Solutions Expert *U2 Family Application Development ------- u2-users mailing list [email protected] To unsubscribe please visit http://listserver.u2ug.org/
