cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Khairudin
Regular Visitor

Help with dates formatting

Hello PowerApps community,

 

I am having some problems getting my dates to display / submit correctly using a Datepicker linked to OneDrive.
Searched multiple previous posts & to my limited knowledge, I figured that I couldn't find the right solution.

My PowerApp:

Annotation 01.png

Fig. 1

 

if(
    IsBlank(ThisItem.SRP_IN),
    "Inducted on: No records",
    "Inducted on: " & Text(
        ThisItem.SRP_IN,
        "[$-en]dd mmmm yyyy"
    )
)

 

Table 1.

As the formula implies, my date should have shown as "Inducted on 01 April 2020 and Expires on 31 March 2022". Instead it shows as shown in Figure 1. Please refer to the formula at Table 1.

This format happens when I logged into PowerApp site, clicked more command (the three dots) and play as seen in Figure 1.

However when I logged into PowerApp site and clicked edit and preview app (F5) , the outcome is to be as expected as seen in Figure 2 (Data is taken here in OneDrive). This confuses me as I think the code is correct.

The weird thing is, not all are displayed incorrectly as shown in Figure 4 taking data from Figure 5.

Annotation 03.png

Fig. 2

My excel in OneDrive:

Annotation 02.png

Fig. 3

Annotation 04.png

Fig. 4

Annotation 05.png

Fig. 5

In summary, date format will show up incorrectly as Figure1 when I logged into PowerApp site, clicked more command (the three dots) and play - Method 1.

Date format is correct as Figure 2 when I logged into PowerApp site and clicked edit and preview app (F5) - Method 2.

Not all are displayed incorrectly during method 1 as seen in Figure 4.

What is going on?

 

Any help would be greatly appreciated!.

Best regard,

Khai

1 ACCEPTED SOLUTION

Accepted Solutions
metsshan
Solution Sage
Solution Sage

Sorry if this is too obvious, but have you Published your app recently? That's the most obvious reason I can think of seeing two different things between Edit and Play.

View solution in original post

2 REPLIES 2
metsshan
Solution Sage
Solution Sage

Sorry if this is too obvious, but have you Published your app recently? That's the most obvious reason I can think of seeing two different things between Edit and Play.

This is not obvious at all. I'll be sure to remember to publish in the future, thanks alot!

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (3,135)