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

Community site session details

Session Id : euiHFN1aHu6t1Om0rG+reS
Power Automate - Building Flows
Unanswered

Complex Flow to Auto Complete Task Items Not working

Like (0) ShareShare
ReportReport
Posted on 24 Dec 2019 18:11:41 by 18

I have a flow that I can’t get to cooperate. I have only been building flows for a few weeks. This is only my 4th flow.

Here’s what I’m trying to do:

I have a list (Tasks) used to sync with Project. Tasks has the following columns:

Tasks List.png

Each Tasks list (Task List content type) has 2,000 to 5,000 items. Users report completion against about 60% of the items, but we would like to complete the rest of the items automatically based on completion of dependent items. The items users report directly against are denoted by “Yes” in the “WR Flag” column. The items not reported against have “No” in that column.

When an item in the table is updated, the flow is triggered and does the following:

  1. Set some variables for later processing

Init Variables.png

Init Variables2.png

  1.  
  2. Check to see if the modified item is now complete

Condition.png

  1. If Yes,
    1. Get items filtered by
      1. NWR Flag is “No”
      2. % Complete < 1
      3. The modified item is a predecessor

Get items.png

  • NOTE: I tried to filter in the same get items statement, but got an error saying that the ‘get items’ couldn’t refer to itself
  • I am also worried that even if I get this to work, the contains statement will bring back erroneous results (e.g. when modified item is ID ‘1’, it will return records where the predecessor ID is ‘16’ or ‘3416’, etc.)
    1.  
    2. Update some variables for use in updating items(s)

Set Variables.png

  • My worry is that % complete won’t be calculated correctly if an item is modified again after it is already complete since I have no way of triggering the flow selectively and don’t know how to set a condition to check if the modification to the item is marking it complete for the first time.

I thought about creating another array column to hold the ‘ID’ of the completed predecessors and then updating it with the current modified ID so I can include it in the condition, but I’m not sure if that will work.

  1.  
  2.  
  3. Update item(s)

Update items.png

  1.  
  2. If No, stop processing.

My error is in the Apply to each 2 Step

Error.png

Any help on this is greatly appreciated!

 

I have the same question (0)

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

MS.Ragavendar – Community Spotlight

We are honored to recognize Ragavendar Swaminatha Subramanian as our September…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 798 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 469 Moderator

#3
Power Apps 1919 Profile Picture

Power Apps 1919 333

Last 30 days Overall leaderboard