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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Delete completed Micro...
Power Automate
Answered

Delete completed Microsoft Planner task after it is older than X days

(0) ShareShare
ReportReport
Posted on by 13

I have created a flow to delete Microsoft planner tasks once they have aged 70 days. I tested the flow, and it tested successfully, however the final task of deleting a planner card did not happen due to an action branching condition not satisfied. I will post screenshots of my flow below.

 

scren_2-1713812910364.png

 

 

scren_1-1713812891440.png

 

 

scren_0-1713812874468.png

why is going to the "if not" condition instead of calculating the completion data is less than the calculated time so I will delete the ID of this task

 

Categories:
I have the same question (0)
  • Verified answer
    v-yetonggu-msft Profile Picture
    Microsoft Employee on at

    Hi @scren ,

    Please check this test:

    I use a scheduled flow that runs every morning at nine o'clock (East 8th District).

    Because my area is UTC+8, the flow uses the world standard time format, so I converted utcNow() to UTC+8 format. 

    And then determine whether the task is satisfactory for completion in the past 70 days.

    vyetonggumsft_0-1713834570176.png

    utcNow()

    vyetonggumsft_1-1713834642224.png

    formatDateTime(items('Apply_to_each')?['completedDateTime'],'yyyy-MM-dd')
    addDays(utcNow(),-70,'yyyy-MM-dd')

    Best Regards,

    Sunshine Gu

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 468

#2
Haque Profile Picture

Haque 370

#3
Valantis Profile Picture

Valantis 354

Last 30 days Overall leaderboard