0

I am new to Power Automate and I am trying to build a process that will notify my team when a file of a certain title is created or modified in our Sharepoint site. There are hundreds of files nested in dozens of subfolders, but they are all housed in 1 root folder (library). Each team member manages the sub folders within the main folder, and at any point, they will have a Word Doc that will have in the title the words "Key Logistics". The rest of the title will vary by client and time of year, but I want Power Automate to send an email notification any time a file containing the words "Key Logistics" is either added or modified.

I found this resources: Send an email when sharepoint file is updated and it ALMOST solves my problem. This will send an email when ANY file is added or modified, which could result in dozens of emails per day, most of which are irrelevant. I need to modify it to only send emails when "Key Logistics" documents are updated. I would also like to include the link to the document in the email.

0

option 1: add a condition. should be pretty simple, check the title, if it's the one you want, send the email, if not do nothing. (when you add actions to the flow, once of the choices of things to add is the condition action)

Problem with the above: it will work, but technically the workflow will run for every single document, which counts against your total runs, and also makes debugging tricky. So, I'd suggest:

option 2: trigger conditions. Conceptually pretty similar to the above, just that the condition is checked first. This means that if the condition isn't met, the flow doesn't run. The downside of this is that these are very difficult to create for beginners, as the syntax is weird, and if you don't get it right, there's no debugging info as it didn't run.

So get the condition up and running first to better learn the system, and then perhaps check this post for info on trigger conditions.

0

Try below steps

  1. Create automated flow select When file is created or modified (Properties only)
  2. add condition Name is equal to Key Logistics and IsFolder is equal to false
  3. if yes then send an email Check attached screenshot for reference SendAnEmail
2
  • Thank you @Akshay. This may be more simplified compared to my flow. Mine starts with the same trigger, but then adds the action "Get file properties". From there it goes into my conditions that, when true, the action "Get File Content" is triggered then it sends the email. Are my "Get File Properties" and "Get File Content" steps necessary? It works, but I want to it for as efficiently as possible. My logic is that once a file is created or modified, I need to get the properties of the file to pass into the condition. Then I need to get the contents to pass to the email. Is this necessary? Apr 15 at 16:34
  • If you are using "When a file is created or modified (properties only)" as a first trigger then no need to use "Get file properties" you already have file properties in dynamic content for send an email use "Link to item" property in email body from dynamic content / if you want to send file as an attachment then you need "Get file content" Apr 16 at 4:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.