Multiple attachments


I have a code that creates file basis the row name in execution , the loop runs till row has values now I need all the files which are created at runtime using the row name to get attached in send outlook mail activity .

I created one mailMesssage variable and then used invoke method to add attachments in this mail message . The Parameter I passes is : Direction In , Type : Attachment Value : new Attachment(Path)

Path Variable stores the complete path of file.

Then In send outlook message I added this mailMessage as Forward .

I am getting error as object reference not set to instance of object .
Null reference

Please suggest the resolutions if have.


Try sending direct the email within the loop without using the Invoke Method.

Hope it helps. :wink:

I need to send 1 email with all attachments . Hope it clarifies the query


With the previous update of the activities you can specify the attachment as an array of strings. This should be enough to add all your attachments. Just add all the paths. @XYZ_1991

@XYZ_1991 check this

[Attach multiple files to send outlook messages]