cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Vasil
Level: Power Up

How to count Planner tasks in a bucket?

 
1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: How to count Planner tasks in a bucket?

Hi @Vasil ,

 

If you want to use Flow to get the number of tasks contained in the bucket, please refer to the following method. I will use HTML table to display the number of tasks.

 

  • Initialize an array variable, use List tasks and List buckets action to get all the tasks and buckets.
  • Traverse the value of List buckets output, use Filter array to filter out the same tasks as the current bucket id.
  • Use length() function to get the number of tasks filtered by Filter array and append them to the array variable.

Expression reference:

length(body('Filter_array'))

Image reference:

36.PNG

37.PNG

Flow run history:

38.PNG

 

Please take a try.

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Super User
Super User

Re: How to count Planner tasks in a bucket?

The Planner documentation spells out the available definitions you can utilize, including GetTask_Response and GetTask_Response_V2 among others. You could get the count via a condition, and the Compose action utilizing the Workflow Definition Language

Community Support Team
Community Support Team

Re: How to count Planner tasks in a bucket?

Hi @Vasil ,

 

If you want to use Flow to get the number of tasks contained in the bucket, please refer to the following method. I will use HTML table to display the number of tasks.

 

  • Initialize an array variable, use List tasks and List buckets action to get all the tasks and buckets.
  • Traverse the value of List buckets output, use Filter array to filter out the same tasks as the current bucket id.
  • Use length() function to get the number of tasks filtered by Filter array and append them to the array variable.

Expression reference:

length(body('Filter_array'))

Image reference:

36.PNG

37.PNG

Flow run history:

38.PNG

 

Please take a try.

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 96 members 4,799 guests
Please welcome our newest community members: