Send excel as attachment on email

I am able to send xls as an attachment on email but it ended up as “AT0001.dif” attachment on email

.dif: data interchange format

PSUtilities.email:smtp

contentype:application/vnd.ms-excel
filename:localfile.xls
encoding:base64
charset:utf-8

Can someone suggest how to see .xls file as an attachment

Could you please use pub.client:smtp service with the inputs you mentioned and let us know the result.

Regards,
Sasanka

/email/contenttype = ‘/application/vnd.ms-excel/’(for .xls), ‘/application/vnd.openxmlformats-officedocument.spreadsheetml.sheet/’(for .xlsx),

I have tried providing the path name on attachments/filename and removed all other definitions on attachments and ran the service. It works. If any of the other definitions are provided. i am returning an attachement “XXX.dif”, data interchange format, which can be opened in excel.

It all works thanks for response and can some one tell me how to set priority of importance on pub.client:smtp service.

In the smtp service there is input for “priority” and you can set hardcode value to High

HTH,
RMG

For setting priority of High you need to use mime services to accomplish

pub.mime:createMimeData
pub.mime:addMimeHeader (set inputs under mimeHeader/X-Priority) and map priority (setValue to 1) or X‐Severity =10 etc…
pub.mime:addBodyPart
pub.mime:getEnvelopeStream
pub.client:smtp (map the envStream to mimeStream)
pub.io:closeStream

Please review the documentation also and test the above logic:

Also view this thread:
[url]wmusers.com

HTH,
RMG