cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Frequent Visitor

Attach multiple attachments to approval email

I'm trying to create an approval flow which requires me to attach multiple attachments to the approval email sent out. I'm using "Start and Wait for an Approval" step, with an "attachmentArray" in the attachment section. When I run the flow, the approval step fails:

 

Screenshot 2019-12-06 at 11.43.28 AM.pngScreenshot 2019-12-06 at 11.44.45 AM.pngScreenshot 2019-12-06 at 11.46.08 AM.png

For the "Append to Array" step, I'm using the following expression to get the "ContentBytes":

 

body('Get_attachment_content').$content
 
Any advice?

 

1 ACCEPTED SOLUTION

Accepted Solutions
Dual Super User III
Dual Super User III

Hi @Eyk 

 

The Attachments in Approvals are a bit different. While creating the array you need to use content instead of content bytes. You can checked my solved post here for more: https://powerusers.microsoft.com/t5/General-Power-Automate/Power-Automate-approval-with-Attachments/... 

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

5 REPLIES 5
Super User II
Super User II

Hi @Eyk 

In the append variable action where you are writing in the attachment content can you change the expression to: Base64(<attachementContentsVariable/>).

This should ensure the Base64 representation of the attachment content (the $content) is correctly appended to the variable.

If you're still having an issue, try adding the AttachmentContents variables in it's entirety to the array variable...

HTH

Jay

-------------------------------------------------------------------------

If I have answered your question, please mark your post as Solved.

If you like my response, please give it a Thumbs Up

Hi @Jay-Encodian,

 

I tried your suggestion and changed my expression to:

 

base64(body('Get_attachment_content').$content)
 
but unfortunately, the error persists. I tried attaching the AttachmentContent variable without any success as well. Thanks for the suggestion though!
Dual Super User III
Dual Super User III

Hi @Eyk 

 

The Attachments in Approvals are a bit different. While creating the array you need to use content instead of content bytes. You can checked my solved post here for more: https://powerusers.microsoft.com/t5/General-Power-Automate/Power-Automate-approval-with-Attachments/... 

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

Hi @yashag2255,

 

Thanks for this solution! Tried it and now my attachments are successfully sent with the approval request.

Hi @Eyk 

As per first post 😉

"If you're still having an issue, try adding the Attachment Contents variable in it's entirety to the array variable"

No worries I see you've got it working as @yashag2255 added the same instruction 🙂

My best

Jay

 

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Top Solution Authors
Top Kudoed Authors
Users online (8,867)