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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Power Automate Flow Co...
Power Automate
Unanswered

Power Automate Flow Condition Issue: Incorrectly Evaluating Time Range

(1) ShareShare
ReportReport
Posted on by

Hello everyone,

I'm experiencing an issue with my Power Automate flow, and I could use some help. My flow is designed to send an email when a trigger occurs on SharePoint, but only during the hours of 9:00 AM to 4:00 PM (Eastern Standard Time). If the trigger happens outside this time range, the email should be delayed until 9:00 AM the next day.

Here's the setup:

  1. Get current time: Retrieves the current time in UTC.
  2. Convert time zone: Converts the current UTC time to Eastern Standard Time.
  3. Condition: Checks if the converted time is between 9:00 AM and 4:00 PM.
    • If yes: Sends the email immediately.
    • If no: Uses a "Compose" action to calculate the next 9:00 AM in EST and a "Delay until" action to delay the email until then.

The issue I'm facing is that when I ran a test at 10:00 AM EST, the flow incorrectly evaluated the condition as false and went to the false branch, delaying the email instead of sending it immediately. Also, the "Delay Until" action has a lot of issues. I believe this all stems from my time zone issue, and I am not sure how to fix it. 

Here are the expressions I'm using:

  • Condition:
    @and(
        greaterOrEquals(formatDateTime(convertTimeZone(utcNow(), 'UTC', 'Eastern Standard Time'), 'HH:mm'), '09:00'),
        lessOrEquals(formatDateTime(convertTimeZone(utcNow(), 'UTC', 'Eastern Standard Time'), 'HH:mm'), '16:00')
    )
    
  • Compose (for the false branch):
    addHours(convertTimeZone(startOfDay(addDays(utcNow(), 1)), 'UTC', 'Eastern Standard Time'), 9)
    

Any insights or suggestions on what might be going wrong would be greatly appreciated!

Thank you!

I have the same question (0)
  • DS-24021648-0 Profile Picture
    2 on at
    Can you compare dates directly with a >= or <=?
    Check out this function:
    dateDifference()
     
    Then you can ignore time zones entirely and just check if it's a positive or negative output (To check if it's before or after 9:00 EST)

    But I'm very new to Power Automate so this might be totally wrong :)
     
  • Suggested answer
    David_MA Profile Picture
    12,966 Super User 2025 Season 2 on at
    Try formatting it by including the date in ISO8601 format: yyyy-MM-ddThh:mm:ss as filter queries require this format.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard