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

Building a Flow to automatically save all incoming attachments to (if possible sender-specific) local folders with an approval mail

Hello there,

 

i hope my issue is somehow understandable, as i even have problems describing it in my native language:

 

I want to create a flow that makes a manual saving of e-mails redundant: there is an Outlook inbox that only receives mails of a specific kind, of which the belonging attachments (to 95%) can all be saved in a specific local folder for further processing.

I thought of creating a flow that displays an approval-mail with only the e-mail's title to the responsible person and automatically saves these attachments to a consisting system folder after approved.

 

Im struggling right at the beginnning, as im not that experienced with flow.

I thought of a flow that looks something like this:

1. Outlook - in a 12h interval, check all E-Mail units arrived  (in folder: inbox; attachments: yes)

2. Condition - E-Mail elements equal approved

3. If yes - Apply to all (attachments): Create file (specific path, file name: attachment name, contains: current content)

If not - send mail to other (specific) person: "Some of the E-Mails that have arrived in the last 12h have to be answered/require any kind of action

 

The steps i need help with are the following:

  • Set up a timer to check only after a 12 h interval is finished
  • "Group" E-Mails so that the Approval shows all new Mails at once (so that all can be approved or denied with one click)
  • Create a file from the attachments once approved (right now it shows me "The key \"gateway\" could not be found in the connection profile.\r\nclientRequestId: 18d8addc-bb49-4a97-981f-b6fdc7077663")

 

 

I would be very grateful if anyone that understood could help me with it.

 

Wishing all of you a good start into the week.

 

Greetings from germany

 

Kevin

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Building a Flow to automatically save all incoming attachments to (if possible sender-specific) local folders with an approval mail

Hi @Anonymous ,

 

Thanks for updating.

 

Get emails action will return emails that match the conditions you’ve specified. Such as Fetch only unread messages, include attachments, and Top.

 

By the way, change create file in cloud to create file in file system folder doesn’t matter.

 

Further, if you want to send all the email to approve at a time, please try with the following configuration.

1.PNG2.PNG

 

Best regards,

Mabel

 

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

View solution in original post

3 REPLIES 3
Community Support Team
Community Support Team

Re: Building a Flow to automatically save all incoming attachments to (if possible sender-specific) local folders with an approval mail

Hi @Anonymous ,

 

Do you want to save all the email attachments to a folder once they are approved?

 

I have made the following flow for your reference.

 

If you want to check the email attachments in a 12h interval, you could consider using the trigger Recurrence. Here for testing, I am using a Button trigger.

 

Add the action Initialize variable, set type to String, and Name to Response.

 

Add action Get emails.

 

Add an Apply to each, add a do-until loop. Set it as variable Response is equal to Approve.

 

Within the loop, start and wait for an approval, then the action set variable. Please select dynamic content Response from the approval action to value field.

 

Under the do-until loop, add apply to each 2, get attachment, then create file to OneDrive folder.

 

Images for your reference.

1.PNG2.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Re: Building a Flow to automatically save all incoming attachments to (if possible sender-specific) local folders with an approval mail

Hi @v-yamao-msft,

 

thanks for your fast response and the assistance!

 

Yes, the attachments should be saved to one specific local folder (i changed the create-file-in-cloud action to create-file-in-system-folder action, there shouldnt be any difference, should it?).

 

Update: I got the Flow to work, it only shows 1 email to approve every time i test the flow (despite having more than one new mail from the previous 12 h). Shouldnt the "number of retrieved emails" field make it show all the [declared amount] emails per approval?

 

I hope you can assist me once again, the flow you made as reference is a huge help!

 

Thank in advance.

 

Best Regards,

 

Kevin

 

 

Community Support Team
Community Support Team

Re: Building a Flow to automatically save all incoming attachments to (if possible sender-specific) local folders with an approval mail

Hi @Anonymous ,

 

Thanks for updating.

 

Get emails action will return emails that match the conditions you’ve specified. Such as Fetch only unread messages, include attachments, and Top.

 

By the way, change create file in cloud to create file in file system folder doesn’t matter.

 

Further, if you want to send all the email to approve at a time, please try with the following configuration.

1.PNG2.PNG

 

Best regards,

Mabel

 

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

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

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

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 177 members 6,202 guests
Please welcome our newest community members: