Hi,
Background: I created various flows to create/modify/delete tasks based on a SP List. The premise is to store all key department tasks in the SP List for the whole year.
Flow Needed: I need to create a flow that will allow me to manually trigger to change the status of any "completed" tasks in the specific planner bucket to "not started".
Problem: It seems that any way I try to create the flow, I can never design a flow that allows me to select the specific bucket. Even the flows below will reset all tasks and not just the tasks in the specific bucket.
@martzj Instead of using an Apply to Each to loop through each task and run a condition check to see if the task is complete. It's much more efficient if you use a Filter Array action to filter out the tasks that are complete, then loop through those tasks only. Remember to rename your actions to keep things organized!
To learn more about how to use the Filter Array action, please refer to this YT Tutorial: Are you using the Microsoft Power Automate Filter Action wrong?
In this video tutorial I’ll show you 3 practical ways to use the Filter Array action and how to use it properly.
1️⃣ Cross-Referencing Data
2️⃣ Filtering by Key
3️⃣ Substring Matching
Did you know that the Condition action has a limit of 10 conditions? Although it might look like the Filter Array action can only accept one condition—this is not true. By using the advanced mode you can enter multiple conditions into a Filter Array action with an expression.
IN THIS VIDEO:
✅ 3 Ways to Use the Filter Array Action
✅ How to use the Scope Action to Group Actions
✅ How to Check the Number of Items returned from a Filter Array Action
✅ How to Cross-Reference Data in Excel with a SharePoint List
✅ How the Filter Array Action Works
✅ How to Access the Dynamic Content from a Filter Array Action
✅ How to Filter Items by a Key
✅ How to Filter Items by Matching a Substring
✅ How to Use Multiple Conditions in a Filter Array Action
Add a Filter Array action to your flow. In the from field insert the value dynamic content.
In the fist value field, insert the value Percent Complete dynamic content. Leave the operator as is equal to. In the second value field insert 100.
Whenever I use a Filter Array action, I always like to return the count of items returned in a Compose action. This is helpful when building a flow and can also be used to troubleshoot your flow.
Insert a Compose action. Add an Expression. Use the length() function.
Select the Dynamic content tab and insert the body dynamic content from the Filter Array action into the length() function.
Run a test. Verify the count in the Compose action matches the number of completed tasks in Planner.
Add an Apply to Each action. Insert the Body dynamic content from the Filter Array action.
Insert the Update a task (V2) action to your flow. In the Task Id field, insert the id dynamic content from the Filter Array action. Specifying the bucket isn't required as this action will get the task by the id. Since each task has a unique id it doesn't matter which bucket your task is in.
Important: You must select the id dynamic content from the Filter Array action and not the List tasks action. The Filter Array action has already filtered out the tasks that are complete. If you select the id from the List Tasks action, it'll make the change to all your tasks.
In the Percent Complete field, insert a 0.
Depending on how many tasks you need to "reset" it would be a good idea to turn on the Concurrency Control for the Apply to Each action.
By default, Concurrency Control is disabled, meaning that the Apply to Each action processes tasks sequentially, one after the other. When Concurrency Control is enabled, it allows you to set the degree of parallelism, which is the number of Apply to Each actions you want to run simultaneously.
Enabling this feature means that multiple instances of the Apply to Each action will operate concurrently, which increases the efficiency of your workflow.
Run a test.
Hope this helps!
stampcoin
39
Churchy
20
Chriddle
19
Super User 2025 Season 1