cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
New Member

Create a flow to email whenever a file is added to Sharepoint folder

I am trying to create a flow in Sharepoint that will send an email to everyone who has access to the folder everytime a new file is added.

 

I have found how to send myself an email and how to do this for a list and library in Sharepoint, but not for a folder. 

Any ideas or help is welcome. 

12 REPLIES 12
Highlighted
Super User II
Super User II

Re: Create a flow to email whenever a file is added to Sharepoint folder

@BethD 

Hi there - Is the list of people with access to the folder pretty static?  Or are you looking to get that list when the Flow is triggered, and then email all of those people from that dynamic list?

 

Are they all in the same group?  I think there's a way to get the list of people through the REST API...maybe?  But that's the sticking point for me, the rest seems pretty straight forward.

 

-Ed-

Highlighted
New Member

Re: Create a flow to email whenever a file is added to Sharepoint folder

@edgonzales 



Let me start with I have never used flow before, so I am very new.

I just want it to email the same people each time I add a file to a folder. That list is constant. Right now I have over 50 folders that I do this manually for, so anyhting faster would be great!

 

"I think there's a way to get the list of people through the REST API...maybe?" -- I have no clue what that means. 😞

Highlighted
Super User II
Super User II

Re: Create a flow to email whenever a file is added to Sharepoint folder


@BethD wrote:

@edgonzales 



Let me start with I have never used flow before, so I am very new.

I just want it to email the same people each time I add a file to a folder. That list is constant. Right now I have over 50 folders that I do this manually for, so anyhting faster would be great!

 

"I think there's a way to get the list of people through the REST API...maybe?" -- I have no clue what that means. 😞


There are several templates already available that accomplish what youa re seeking, such as

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Highlighted
New Member

Re: Create a flow to email whenever a file is added to Sharepoint folder

Brad

If you look at the one you sent, it says for Sharepoint library. Which I mentioned I had found in my first post. I need the exact same thing, but for FOLDERS -- which I can only find email myself when a file is added to a folder. I have tried the templates that are already created several times and different ways. None of them do what I need. 

Thanks.

Highlighted
Super User II
Super User II

Re: Create a flow to email whenever a file is added to Sharepoint folder

The logic is exactly the same, but the trigger is for a SharePoint document You won't be able to pull each user who has access to the folder dynamically, but hopefully you aren't assigning users permissions to folders at the user level - that isn't Active Directory best practice.

Group A has rights to Folder A, when a new file is added to Folder A, email Group A. Simple as that. Templates are just guides, the logic in one template can generally be used with other connectors to perform nearly the same functionality. 

Very rarely are you going to find a template that does exactly what you want to do, because your environment and use cases are unique to you. Look at templates as guidance and learning tools, not the end-all-be-all.

Free Flow Training: 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Highlighted
Super User II
Super User II

Re: Create a flow to email whenever a file is added to Sharepoint folder

(Edit: I just read the accent on multiple folders...I'll keep digging).

 

 

On the API, I barely know what it means, as well.  No worries.

Since your list is static, we should be in good shape.

One of my favorite things about Flow is there is always a few ways to do 'a thing'.

Here's one - 

 

You can create one from a blank  - My Flows > Create from Blank (Or new version says "Instant - From Blank)

Search for Sharepoint triggers and find the one that says "When a file is created in a folder"

Ser your site address (drop down) and select the folder.

 

Next, find your email client (Outlook?) and look for an action "Send an email".  Fill out the stuff and try it out.  Here's a pic of one I built:

Capture.PNG

 

Will that work?  Keep us posted and good luck!

-Ed-

Highlighted
New Member

Re: Create a flow to email whenever a file is added to Sharepoint folder

Ok, so I think I am starting to get this. I didn't realize there was a create from blank (see second post I am REALLY new at this). 

 

I think I get it and this will work, but I have a problem. When I click on folder id it tells me I don't have permission. Is there another way to get the folder id? I have multiple folders within other folders that I will need to do this for, so I can't just say the parent folder and be done. Smiley Sad

 

Highlighted
Super User II
Super User II

Re: Create a flow to email whenever a file is added to Sharepoint folder

@BethD 

I might not make any friends with the cool Flow kids, but would Sharepoint Alerts work?  Seems like that might do the trick.

Highlighted
New Member

Re: Create a flow to email whenever a file is added to Sharepoint folder

I tried that first, but each person has to set them up and they didn't so..... 😞

Highlighted
Super User II
Super User II

Re: Create a flow to email whenever a file is added to Sharepoint folder


@BethD wrote:

Ok, so I think I am starting to get this. I didn't realize there was a create from blank (see second post I am REALLY new at this). 

 

I think I get it and this will work, but I have a problem. When I click on folder id it tells me I don't have permission. Is there another way to get the folder id? I have multiple folders within other folders that I will need to do this for, so I can't just say the parent folder and be done. Smiley Sad

 


So, you've set the site address in the top field already, and then you get an error as soon as you click the folder icon? Or when you select a folder?

For the other folders, you can copy the initial Flow by doing a Save As, and then go change the folder.  Not ideal, but also not creating it from scratch.

Too bad there isn't like a Sharepoint log or something that tracks when files are created and you could just watch that as your trigger.  I wish I knew more about Sharepoint.

 

Keep us posted.  Almost there!

-Ed-

Highlighted
New Member

Re: Create a flow to email whenever a file is added to Sharepoint folder

I get the error message when I try to click the folder icon to select one. Here's a screenshot:

Microsoft Edge 2019-05-03 16.07.51.png

Highlighted
Super User II
Super User II

Re: Create a flow to email whenever a file is added to Sharepoint folder


@BethD wrote:

I get the error message when I try to click the folder icon to select one. Here's a screenshot:

Microsoft Edge 2019-05-03 16.07.51.png


Ok, I have 'phenomenal cosmic power' so probably can't replicate the issue, but it might be because the folder-picker starts at the 'root', and you probably don't have access to that part to choose the folder you do have access to.

 

Try hand-typing in that field (use forward slashes... "/") like my example above to replicate the path to see if that works...something like this:

"/Shared Documents/Folders/BethD"   - If that by itself doesn't work, try typing it out and then clicking the folder icon...(thinking the path will give it a starting point to where you do have access).

Another option might be to chat with your SP Admins to see if they can grant you access long enough to build the Flows.

Keep at it.

-Ed-

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

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

Users online (6,171)