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 Apps / Text( Now(),DateTimeFo...
Power Apps
Answered

Text( Now(),DateTimeFormat.ShortTime,"en-GB") returns DateTimeFormat.ShortTime24

(0) ShareShare
ReportReport
Posted on by 20
Pretty much what the subject says:
Text( Now(),DateTimeFormat.ShortTime,"en-GB")
Returns the time in ShortTime24 format (23:45 rather than 11:45 PM) when the locale is "en-GB". This is the case when the locale is auto-detected or specified (as shown). However, DateTimeFormat.ShortTime works as expected with "en-US". Using DateTimeFormat.LongTime with "en-GB" has the same issue except it returns LongTime24 (which is something, I guess!)
Categories:
I have the same question (0)
  • Suggested answer
    Power Platform 1919 Profile Picture
    2,254 Super User 2026 Season 1 on at
    Hi @philip_dt,
    can you please try this formula:

    // 12‑hour for any user
    Text( Now(), "h:mm AM/PM" )
     
    // 12‑hour but parse for GB local .
    Text( Now(), "[$-en-GB]h:mm AM/PM" )

     
    you can get more info  about showing dates and time in canvas apps from this article !!!
  • Verified answer
    DP_Prabh Profile Picture
    381 on at

    This is expected behavior in Power Apps.

    For en-GB, the regional standard uses the 24-hour clock, so:

    • DateTimeFormat.ShortTime → 23:45

    • DateTimeFormat.LongTime → 23:45:00

    If you need 12-hour format with AM/PM, don’t rely on DateTimeFormat. Use an explicit format string:

    Text(Now(), "[$-en-GB]hh:mm AM/PM")
    

    This ensures consistent 12-hour formatting regardless of locale or environment.

    I hope this works for you!

  • Verified answer
    11manish Profile Picture
    3,333 on at
    n Power Apps, the DateTimeFormat.ShortTime enumeration is designed to be locale-aware, meaning it follows the regional standards of the specified locale. For the "en-GB" (United Kingdom) locale, the standard time representation is the 24-hour clock (e.g., 23:45), which is why you see it returning what appears to be ShortTime24. 

    In contrast, the "en-US" (United States) locale defaults to a 12-hour clock with an AM/PM designator (e.g., 11:45 PM).
     
    Reference:
     
  • philip_dt Profile Picture
    20 on at
    For en-GB, the regional standard uses the 24-hour clock
    Huh. Well, I never knew! Only worked in en-GB my whole life.
     
    However, that being the case, the "docs" at https://learn.microsoft.com/en-us/power-platform/power-fx/reference/function-text are poor. There is no mention of "regional standards" on the page and the section on "Predefined date/time formats" doesn't even mention locale.
     
    In that section, ShortTime enumeration is simply described as "Hour (12-hour clock), minutes, and AM/PM designation." Apparently that's not what it does at all!

    Does ShortTime24 in fact override the regional standard of the specified locale and force 24-hour clock?
     
     

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 May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 424

#2
WarrenBelz Profile Picture

WarrenBelz 355 Most Valuable Professional

#3
11manish Profile Picture

11manish 290

Last 30 days Overall leaderboard