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

Handling single / multiple attachments - when a new email arrives in a shared mailbox

When an email with attachments arrives in a shared mailbox, I would like to forward it to a distribution list (along with the attachment/s and then start an approval process. However, i am stuck at the first step ie. forwarding it to a distribution list

 

any help in this regard is appreciated. 

 

ERROR message: One or more fields provided is of type 'Null', a different type is expected.

 

flow.PNGflow 2.PNG

 

PS: the incoming email might have multiple attachments and 

1 ACCEPTED SOLUTION

Accepted Solutions

Hello @ramakrishnanpr 

You are right, as it seems that msg files are not recognized by Power Automate. Read this post with the same issue as yours: https://powerusers.microsoft.com/t5/Building-Flows/Saving-email-attachments-msg-with-flow/td-p/26069...

Hope it helps!

Ferran

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

View solution in original post

6 REPLIES 6
fchopo
Super User
Super User

Hello @ramakrishnanpr 

As you don't know the number of the attachments you are going to receive in the shared mailbox, you should save them in one single variable and send only one email. Have a look at this post: https://flow.microsoft.com/en-us/blog/multiple-attachments-single-email/

Apart from that, you should check you have permissions on the shared mailbox to send emails.

I attach an example:

flow.png

 

In the "send an email from a shared mailbox" you have to click the icon near the attachments section to change its view, and allow the insertion of a variable.

Hope it helps!

Ferran

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

Thanks @fchopo 

For sure i have the permission in the shared mailbox. I did try your solution but still get an error 

 

Parameter 'Attachment Content' cannot be null or empty.

 

error 1.PNG

 

error 2.PNG

 

Output:

error.PNG

for reasons not known to me my "when a email arrives in a shared mailbox" recognizes only 1 of the two attachments. additionally the contentBytes is null at this level itself?

 

Any idea why this is happening?

 

attachment.PNG

Hello @ramakrishnanpr 

Have you tried with different emails and attachments? Maybe it's something with the attachment, since it should'nt be null!

Regards,

Ferran

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

I think the prob is that the ,msg files are not recognized by the system, it works fine with other types. Any reason / solution for the same?

Hello @ramakrishnanpr 

You are right, as it seems that msg files are not recognized by Power Automate. Read this post with the same issue as yours: https://powerusers.microsoft.com/t5/Building-Flows/Saving-email-attachments-msg-with-flow/td-p/26069...

Hope it helps!

Ferran

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Kudoed Authors
Users online (2,964)