I am trying to create a new email from command line and automatically add an attachment. The following is the closest I have gotten, it works apart from adding the attachment. I have also tried using &attach=... and &attachment=...

start mailto:emailadress?subject=My email&body=some text&attachments="c:/AUTOEXEC.BAT"


I figured it out. It works using the following commmand:

C:\Program Files\IBM\Lotus\Notes>notes mailto:email@address.com?attach=c:\autoexec.bat


Thanks, just what i needed!

If you still want subject and body you'd have to escape the "&" (with ^). Else it is interpreted as a new command. e.g.:

C:\Program Files\IBM\Lotus\Notes>notes mailto:email@address.com?subject=My email^&body=some text^&attach=c:\autoexec.bat

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.