Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Unanswered

Download specific email attachment and post to sharepoint

(0) ShareShare
ReportReport
Posted on by 32

I receive an email every week and post the attachment (report 1) to sharepoint. However, the user also has other attachments in the email (report 2 and email signature that is a picture). Is there a way to only download and post report 1 and ignore report 2 and the email signature? 

  • gabequinn__ Profile Picture
    32 on at
    Re: Download specific email attachment and post to sharepoint

    I tried that. It says it successfully posted but now there is no file in the sharepoint site. So confused. 

  • Unknown geen idee Profile Picture
    1,755 on at
    Re: Download specific email attachment and post to sharepoint

    Did you put an '.xlsx' behind the filename?

  • gabequinn__ Profile Picture
    32 on at
    Re: Download specific email attachment and post to sharepoint

    Thanks @Koen5 !

     

    I did that but when I post the attachment to sharepoint, its not in Excel format (like the attachment) but in a File format. Thoughts? 

     

    Here's the flow and the resulting file 

    gabequinn___0-1680553287071.png

     

    gabequinn___1-1680553331631.png

     

  • Unknown geen idee Profile Picture
    1,755 on at
    Re: Download specific email attachment and post to sharepoint

    Dear Gabequinn,

    I gave it a try myself and realized that the output from the trigger is already an array with the attachments .... hence you do not need to use a 'Get attachments' actions.

    View example below and you should be good:

    Koen5_0-1680530491673.png

     

     

    Happy flowing,

    Koen

  • gabequinn__ Profile Picture
    32 on at
    Re: Download specific email attachment and post to sharepoint

    Thanks for the response @ko 

     

    I tried get attachments and got the error "ID malformed"

     

    Here is what it looks like currently: 

    gabequinn___0-1680529528513.png

     

    Thoughts?

     

  • Unknown geen idee Profile Picture
    1,755 on at
    Re: Download specific email attachment and post to sharepoint

    Dear Gabequinn,

    I assume you are using a trigger "When new email arrives" or an action "Get emails" for Outlook.

    If the attachment you need to get always has the same name ... or has a name-syntax which you can predict, then you should be able to use the following sequence of actions:

    • Get attachments
      • This will get you an array output of all the attachments.
    • Filter array
      • Filter the output from the previous action based on your filename/filename syntax.
    • ... use the output of filter array in your ongoing actions ... for example to save the attachment in the sharepoint.

     

    Hope the suggestion helps,

    Happy flowing,

    Koen

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1