web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Automatically attachin...
Power Automate
Unanswered

Automatically attaching SharePoint docs during the week to send in an Outlook email

(0) ShareShare
ReportReport
Posted on by 4
Please bare with me as I am brand spanking new to Power Automate.  I am using the web based version of Power Automate.
 
These are the instructions.
 
-----------------------------------
 

I’m looking to see if we can automate the following:

  • Once documents are uploaded, group them into batches of 10

  • For each batch, generate and send an email to the MA regulator with those 10 documents attached

  • After sending, move those 10 documents into a separate folder labeled something like:

    MMDDYYYY – Batch 1, Batch 2, etc. (so we have a clear audit trail of what was sent with each email)

A few additional parameters:

  • The source folders are currently organized by month, but batching should occur regardless of folder structure

  • If more than 10 documents are received, multiple batches should be sent (always in increments of 10)

  • Ideally, we do not send emails with fewer than 10 documents

  • This process does not need to run daily—a weekly run (e.g., Fridays) would work, where:

    • All documents for the week are grouped into batches of 10

    • Any remainder (<10) rolls into the following week

Additionally, I’d like to be CC’d on all outgoing emails so I can track submissions for billing purposes.

 

--------------------------------------------

 

First off, are all these options possible?

 

This seems to me that several flows need to be created and then joined together. 

 

It seems all straight forward for the most part, but because I know nothing about Power Automate, I'd appreciate any help that can be provided.  In the meantime, I watching videos on it and it is getting a bit easier to understand and I was able to send myself an email, but that is the least of my issues.

 

Thanks

 
 
Categories:
I have the same question (0)
  • CU27030035-0 Profile Picture
    105 on at
    A couple of ways to do this 
    Personally I would probably do this in 2 flows 
    I would group the documents together in a SharePoint list then use a recuring flow to send and log
    SharePoint list will need a choice field "Status" values of "Uploading documents", Ready for Export" and "Exported"
    Not sure how you get your files so I'm speculating a bit but
     
    1st flow
    When a file is uploaded get the file
    Get everything in the list where we are grouping them
    Get the attachments on said item 
    Count the Number of attachments (initialize a variable at the start of the flow and then for each attachment increment it)
    Use a control that if number of attachments is greater than or equal to 10
    if less then add it to this item
    If 10 Change the status of this list item to ready for export and add a new list item and add attachment to that set the status value as uploading documents
    (Note: if you are uploading multiple documents at a time you will need to put this in a for each loop)
     
    2nd flow
    Recuring every Friday at whatever time
    Get items from the list
    inside a for each if status equals Ready for export 
    Get attachments and put them on an email and send it 
    Then Create a folder in your document library with your naming convention and add the attachments in there 
    Finally update the list item to Exported so it doesn't pick it up twice
     
    Alternatively you could add the export Audit data to the SharePoint list in a column this is what I would do but I don't know your auditing requirements so I'll Let you decide on that 
     
    If you are storing all these in files you will probably want to have a 3rd flow running to delete any items with a status of Exported to keep the runtime down
     
     
  • Jim Kimball Profile Picture
    4 on at
    That really seems the logical way to approach this.  After I submitted this post, I came across making a list and a few things became more clear to me in the context of how to segregate the new docs and be able to concentrate my efforts within that first level of flow.
     
    I will be attacking this again in the morning with a fresh new base of understanding of this, so I really appreciate how you laid this out.  Now I just need to see if I can follow through accordingly.  I also need to see how much leeway I have in creating the new list to contain these docs as far as my Manager is concerned and the employees that add these docs to it, but since she wants this done, I guess I have that freedom to create what is needed.
     
    This is a great place to start and I really appreciate your help and will tag this response accordingly once I am able to work on your game plan and see my results.  Let's see how much I can accomplish in the morning.
     
    Thank you.
  • Jim Kimball Profile Picture
    4 on at
    I wish I could report back that I have made good progress, but I am still having issues.  I can't even get an email sent to myself anymore.  It worked yesterday, but today I have run the test numerous times, but just cannot get an email.
     
    The flow triggers when I add a file to SharePoint, so at least that works.  The flow reports back that there are no errors, so I can't even begin to understand what the issue(s) is/are.
     
    The run history shows the last handful of tests as Succeeded, but Analytics/Usage shows as 0 flow runs.  So which is it?  Is it working (somewhat) or not?
  • CU27030035-0 Profile Picture
    105 on at
    If the flow is not failing but your not getting the email its most likely one of 3 things 
     
    1st you've got an email security system at the enterprise level and its flagging/Blocking the email for some reason most likely impersonation since Microsoft is sending an email on your behalf 
     
    2nd your outlook is moving it either to Junk/Spam or you have some sort of rule causing it to move 
     
    3rd you've put the address in wrong (But you said it worked the other day so probably not it but worth checking regardless)
     
    How we check 
     
    If you have access to the exchange admin centre you can do a message trace this will tell you if it was moved and to where if it hit your exchange server 
    if you can't find it there it never got that far and was likely blocked by enterprise level security (there will be a log in that somewhere)
     
    Weather you can or can't access those though the way easiest way to check is to send to a different email address (probably a Gmail if you have one, if not you can just set one up real quick)
    Gmail would have none of your enterprise security and none of your outlook rules (Especially if its freshly created)  
     
  • Ellis Karim Profile Picture
    12,163 Super User 2026 Season 1 on at
    Please share a screenshot of your flow, showing the configured actions. Be careful not to include any sensitive or personal information. This will help us understand the issue and provide a solution faster. Thank you!
     
    Ellis Karim
    Ellis Karim
    elliskarim.com  |  LinkedIn  |  Bluesky
    If this solved your issue, please mark it as ✅ Accepted Answer. If it helped, feel free to give it a 🩷 Like!
     

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Valantis Profile Picture

Valantis 377

#2
11manish Profile Picture

11manish 279

#3
David_MA Profile Picture

David_MA 234 Super User 2026 Season 1

Last 30 days Overall leaderboard