cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Help Needed - Save my Specific Email Attachments to a Sharepoint Library

Hi, 

 

I have a question with uploading attachment in my received email to SharePoint with Flow. 

 

I've been using the Save my Email Attachments to a Sharepoint Document Library and so far it is working well. My problem with it now is that it uploads all the attachments in the email (including pasted images on the email body). I would just like to ask if there is a way to only upload a specific file type when using this template? 

 

Please prompt me for more details if you think you may have an explanation or a solution.

Thank you.

1 REPLY 1
Community Support
Community Support

Re: Help Needed - Save my Specific Email Attachments to a Sharepoint Library

Hi @Anonymous,

 

We could add a condition to filter the Attachment Name, so only filtered attachment could be saved, the following example would only save the .txt file:

5.PNG

If you would like to filter other file type, then please click the Condition Advanced mode, and input the filter formula, for example, we would like to filter .doc,  .docx, .txt, .xlsx, the formula should be:

@or(
       contains(item()?['Name'], '.txt'),
     or( 
          contains(item()?['Name'], '.xlsx'),
          or( 
             contains(item()?['Name'], '.docx'),
             contains(item()?['Name'], '.doc')
              )
         )
  )

If you need any further help on this, please post back.

Regards

Michael

 

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Automate Community!

firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Users online (8,234)