cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
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
Highlighted
Dual Super User III
Dual Super User III

Re: Attach multiple attachments to approval email

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
Highlighted
Super User II
Super User II

Re: Attach multiple attachments to approval email

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

Highlighted
Frequent Visitor

Re: Attach multiple attachments to approval email

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!
Highlighted
Dual Super User III
Dual Super User III

Re: Attach multiple attachments to approval email

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

Highlighted
Frequent Visitor

Re: Attach multiple attachments to approval email

Hi @yashag2255,

 

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

Highlighted
Super User II
Super User II

Re: Attach multiple attachments to approval email

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!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (6,795)