mailsend icon indicating copy to clipboard operation
mailsend copied to clipboard

Can't get attachments to work

Open bcosell opened this issue 2 years ago • 3 comments

in my mailsend command line, it ends with

-msg-body "d:/perl/nplmail.20528.txt" -attach "d:/perl/nplmailattach.20528.txt" -v -show-attach

The files for the attachment is there [I've double checked] but nothing is attached to my message [and that's confirmed by the absence of any attachment in the -v log info] What am I doing wrong?? THANKS

bcosell avatar May 09 '22 14:05 bcosell

Just to clarify in case I made some other error in the command line I've tried:

mailsend.exe -ct 600 -read-timeout 600 -smtp -ssl -port 465 -auth -domain <> +bc -f [email protected] -mime-type "text/plain" -name "Name" -user -pass "PW" -to [email protected] -sub "attachment test" -msg-body "message.txt" -v -aname "attachment" -attach "attachment.txt" -show-attach

And the message comes through without an attachment (-v printout says the same thing). This all with mailsend.19

bcosell avatar May 10 '22 14:05 bcosell

If -msg-body is used, only one file can be "included", all other attachments will be ignored. It is mentioned in FAQ #1. Including a file as body and attachments can not be mixed. "include" means it just adds the file as body like old school mail without any MIME type. You can try sending all files as attachments and first one as -attach "file,mime-type,i". Most mail readers will show it as body - also mentioned in FAQ# 1. Also you might have better luck with mailsend-go

Thanks.

muquit avatar May 12 '22 15:05 muquit

Thanks for the info. I didn't see that there were FAQs. But I've taken your advice and just downloaded mailsend-go. THANKS!

bcosell avatar May 18 '22 00:05 bcosell