Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - General Discussion
Answered

Email when Planner Task is coming 3 days from Due

(0) ShareShare
ReportReport
Posted on by 58

Hello everybody,

 

My organization turned off the ability to receive emails when a task is come within 7 days due, or past due.  I am looking to create a flow to do this for my managers.  I would like it to send an email to all assignees of each task coming due within 3 days.  I am having many issues, and what seemed to be easy, is obviously not easy for me! I attached what I have currently tried thus far.  all help appreciated, thank you for your time. 

 

Some issues:

Condition 1: Not all my tasks had the category of dueDateTime in the "Body", so I had to try and take out the ones that were null. 

Condition 2: Tried to reformat the date to what it is in the planner and get rid of the time so that it would always match on just the date.  Does not separate them like I wanted them to.  

 

Respectfully,

Jesse

Format Date =

formatDateTime(items('Apply_to_each_2')?['dueDateTime'],'mm/dd/yyyy')
 
Get future date =
getFutureTime(3,'Day','mm/dd/yyyy')
  • alvinlee Profile Picture
    10 on at
    Re: Email when Planner Task is coming 3 days from Due

    Hi I would also like to get some help. I created something similar here as I like to send the assigned user a reminder with a specific message of the action to take when the planner task is due.

     

    alvinlee_0-1720919251287.png

     

    This is the error that I get. May I check would you be able to advice what went wrong?

    alvinlee_1-1720919407895.png

     

  • ADGToreUp Profile Picture
    58 on at
    Re: Email when Planner Task is coming 3 days from Due

    Thank you, again!  Works perfect.  I tried the same but without the extra 'and()' statement.  still not quite sure why the extra 'and()' is needed, but this whole thing has taught me a lot.  I appreciate the help. 

  • Verified answer
    Expiscornovus Profile Picture
    32,155 Most Valuable Professional on at
    Re: Email when Planner Task is coming 3 days from Due

    Hi @ADGToreUp,

     

    Can you try this:

    @and(and(not(equals(item()?['percentComplete'], 100)),equals(empty(item()?['dueDateTime']), false)), equals(formatdateTime(item()?['dueDateTime'], 'yyyy-MM-dd'), addDays(utcNow(), 3, 'yyyy-MM-dd')))
  • ADGToreUp Profile Picture
    58 on at
    Re: Email when Planner Task is coming 3 days from Due

    I apoligize to continually bug you, but i have one more item.  It all worked great, but then I just found out that it sent emails to people on the correct due dates, but their tasks were completed already.  I tried many ways to add this to the filter, but cannot get anything to stick.  This is what I tried below... (What I added is orange text) 

     

    @And(less(item()?['percentComplete'], 100), equals(empty(item()?['dueDateTime']), false), equals(formatdateTime(item()?['dueDateTime'], 'yyyy-MM-dd'), addDays(utcNow(), 3, 'yyyy-MM-dd'))))

  • ADGToreUp Profile Picture
    58 on at
    Re: Email when Planner Task is coming 3 days from Due

    You my friend, are a genius! I really appreciate your help.  Not sure why I am struggling so much with this, just as I was getting good with VBA and great with Excel functions, my organization changed over to this new software.  Great software, just struggling on learning the new! lol

  • Verified answer
    Expiscornovus Profile Picture
    32,155 Most Valuable Professional on at
    Re: Email when Planner Task is coming 3 days from Due

    Hi @ADGToreUp,

     

    You can use the body of the Filter Array to loop through. The _assignments array with assigned users should still be available.

     

    Below is an example.

    In this example I assumed you want to sent an email per task to each individual assignee. There are also different approaches (like grouping the tasks per assigned user), but those require a different setup.

     

    1. First apply to each loop

    body('Filter_array')

     

    2. Nested apply to each loop

    items('Apply_to_each')?['_assignments']

     

    3. Get User Profile (v2)

    item()['userId']

     

    emailpertask.png

  • ADGToreUp Profile Picture
    58 on at
    Re: Email when Planner Task is coming 3 days from Due

    This does bring one other issue.  When I try to 'get user profile' it no longer gives me the option to get the info for the assignee.  I use this to send the email.  is there another way around that, or a way to add in the filter to give me that information also? 

  • ADGToreUp Profile Picture
    58 on at
    Re: Email when Planner Task is coming 3 days from Due

    Super cool! Thank you! 

  • Verified answer
    Expiscornovus Profile Picture
    32,155 Most Valuable Professional on at
    Re: Email when Planner Task is coming 3 days from Due

    Hi @ADGToreUp,

     

    You can use a Filter Array action for this. This way you don't have to loop through every single task for the filtering part. After that you can use the outputs of the Filter Array for the notifications.

     

    Below is an example

    In this example the expression checks if the due date is not null and also compares it with 3 days from now.

     

    Add this in the advanced mode:

    @and(equals(empty(item()?['dueDateTime']), false), equals(formatdateTime(item()?['dueDateTime'], 'yyyy-MM-dd'), addDays(utcNow(), 3, 'yyyy-MM-dd')))

     

    filterarray_due3days.PNG

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1