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

I need to check for a mail attachment on Outlook on Saturdays only and save the attachment to SP.

I have created a flow to check new emails for a specific attachment and save it to a SharePoint library and it works perfect, but I need this to only check for emails on Satuday at 12:00 noon.  When I start the flow woth a reoccurence then add the rest of my script things change in what it will accept and I can't get it to work with the schedule being added. 

 

Does any one know how to do this?  I have watched lots of youtube videos and searched for articles on this but can't fine this specific type script.

 

Thanks

2 ACCEPTED SOLUTIONS

Accepted Solutions

Hi @ MichaelRobey,

 

You could add a Condition 2 inside the "Apply to each 2",and move the "Create file" action inside the if yes branch of the Condition2 as screenshot below:

Capture.PNG

 

The expression in the Condition 2 as below:

@equals(first(skip(split(items('Apply_to_each_2')?['Name'], '.'), 1)), 'csv')

Please let me know if your problem is solved.

 

 

 

 

Regards,
Alice Zhang

View solution in original post

I finally have this working as I want.  Thanks for all the support and help.  Really appreciated.

View solution in original post

6 REPLIES 6
v-yuazh-msft
Community Support
Community Support

Hi @ MichaelRobey,

 

Could you please share a screenshot of the configuration of your flow?

 

Do you want to check for mails on Outlook on Satuday at 12:00 every week?

How would you check for the mails and save the attachment of the emails to sharepoint library?

 

For you first question:check for mails on Outlook on Satuday at 12:00 every week and save the attachment of the emails to sharepoint library

 

I have made a test on my side, you could refer to screenshot below to check for mails on Outlook on Satuday at 12:00 every week and save the attachment of the emails to sharepoint library:

Capture.PNG

Capture.PNG

 

I would check for the emails which's subject is equal to New test on this flow, you could modify the condition as you needs to check for the email.

 

The flow would run successfully to check for the emails which's subject is equal to New test and crea te the attachment in the sharepoint library as below:

Capture.PNG

 

 

For you second question:then add the rest of my script things change in what it will accept and I can't get it to work with the schedule being added.

Could you please explain more about the script taht you mentioned?

Could you please share more details about your needs?

Please share more details so we could try to help you.

 

Regards,
Alice Zhang

Not sure how to add in some screen prints of what I have.  I made it a bit further, but now when it copies the file in to the sharepoint library it also copies other things like the logo, signature etc...  I'm using a Condition of Name is equal to the file name, but it still is copying in the other items as well. I will add screen prints if you can explain how.  It seems like I can only enter in text.

I have it working using your idea above except it not only copied the file I want but the logo signatures etc 4 extra files which are all .png files.  How do I weed these out so only the 1 file that ends with .csv gets copied to sharepoint?

Hi @ MichaelRobey,

 

You could add a Condition 2 inside the "Apply to each 2",and move the "Create file" action inside the if yes branch of the Condition2 as screenshot below:

Capture.PNG

 

The expression in the Condition 2 as below:

@equals(first(skip(split(items('Apply_to_each_2')?['Name'], '.'), 1)), 'csv')

Please let me know if your problem is solved.

 

 

 

 

Regards,
Alice Zhang

View solution in original post

This is what I have created. 

 

On the first condition if I have it set to Subject is equal to New Test and manually run it it works but not if I wait for the scheduled time to do it.  I put Name is equal to MT20.csv file as this is what I thought we would want as the Subject line may change.  Can you help me get this working?  Am I close or have I missed something.

 

Thanks

 

 

Recurrence.JPGGet Emails.JPGBody.JPGCondition and Create File.JPG

I finally have this working as I want.  Thanks for all the support and help.  Really appreciated.

View solution in original post

Helpful resources

Announcements
MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MSFTBizAppsLaunchEvent

Experience what’s next for Power Virtual Agents

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Users online (46,688)