<img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=612681139262614&amp;ev=PageView&amp;noscript=1">
Skip to content

Need help? Talk to an expert: phone(904) 638-5743

How to Filter Email Attachments with Power Automate

How to Filter Email Attachments with Power Automate

Filtering Email Attachments with Power Automate

Power Automate is a powerful tool that helps automate repetitive tasks, such as managing incoming email attachments. In this tutorial, Jonathan Silva from Pragmatic Works walks through how to filter email attachments using Power Automate. This allows users to save only specific file types while ignoring unnecessary ones, such as email signatures.

 

 

Setting Up the Workflow

Jonathan begins by demonstrating a Power Automate workflow that triggers when a new email arrives. The workflow includes filtering parameters that ensure only emails with attachments are processed. The key steps include:

  • Setting up a trigger for when a new email arrives.
  • Applying a filter to process only emails containing attachments.
  • Using a “For Each” loop to iterate through all attachments.
  • Adding a “Get Attachment” action to retrieve metadata.

Filtering Attachments by File Type

To filter attachments based on file types, Jonathan uses the **file name extension** within the workflow. The process involves:

  1. Extracting the file name and its extension from the dynamic content.
  2. Setting a condition to check if the file name contains a specific extension (e.g., PDF or XLSX).
  3. Saving only the filtered attachments to OneDrive.

This ensures that only the required file types are stored, while unnecessary ones are ignored.

Handling Inline Attachments (Email Signatures)

Jonathan also covers how to exclude email signatures, which often get detected as attachments. To handle this, he:

  • Uses the “Attachment Is Inline” property from dynamic content.
  • Sets a condition to exclude attachments where this property is set to "true."
  • Ensures that only actual file attachments are saved, avoiding unwanted images from email footers.

Testing and Verifying the Workflow

After configuring the workflow, Jonathan tests it by sending an email with multiple attachments, including a signature image. The results show:

  • Only files matching the set filters (PDF and XLSX) are saved.
  • The email signature is ignored, keeping the file storage clean.

Conclusion

By following this process, users can automate email attachment filtering in Power Automate, saving only relevant files while preventing clutter from unnecessary attachments. This workflow helps streamline email processing and ensures that only important documents are stored.

Don't forget to check out the Pragmatic Works' on-demand learning platform for more insightful content and training sessions on Power Automate and other Microsoft applications. Be sure to subscribe to the Pragmatic Works YouTube channel to stay up-to-date on the latest tips and tricks.

Sign-up now and get instant access

Leave a comment

Free Community Plan

On-demand learning

Most Recent

private training

Hackathons, enterprise training, virtual monitoring