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 / Formatting for Date An...
Power Apps
Answered

Formatting for Date And Time in Data Table from Excel Connected table

(0) ShareShare
ReportReport
Posted on by 23

I have spent 5 hours scouring the interwebs for the answer.

 

I have an Excel table with a single row showing the LastRefresh of it's dataset. 

I want to display this date and time in my Powerapp. 

 

Here is what it looks like in Excel

RowLastRefresh
07/7/2021 7:16 PM

 

When I format the value in Excel to Date/Time like above, it shows no data in the powerapp

When I format the value in Excel as General it changes to : 44547.763045

This does show up in the power app but is not useful to my users.

 

I can get the date ONLY to show up using 

Text(DateAdd(Date(1900, 1, 1), ThisItem.LastRefresh - 2, Days),"[$-en-US]mm/dd/yyyy")

 

But if I add the time to the end of the format I get 00:00:00, probably because I'm doing the DateAdd against a date only so it uses midnight from my Date.

 

I've tried to change the text of the field in the Data Table.

I've tried DateTimeValue(ThisItem.LastRefresh) : shows blank

I've tried Text(ThisItem.LastRefresh, "mm/dd/yyyy hh:mm:ss") : shows 44547.763045

I've tried Text(ThisItem.LastRefresh, LongDateTime24) : shows 44547.763045

 

I've even tried the convert to local dataset using the Screen.OnVisible command creating a FormattedLastRefresh column : 44547.763045

 

I've tried to do a lookup from a Label : all the same as above.

 

I am at a LOSS!

 

Thank you, in advance, for any help you can provide.

 

Regards,
Matt

Categories:
  • Verified answer
    MattSuderman Profile Picture
    23 on at

    Solved it!

     

    I changed the field value in excel to :

    =+MONTH(LastRefresh[LastRefresh]) &"/" & DAY(LastRefresh[LastRefresh]) &"/" & YEAR(LastRefresh[LastRefresh]) &" " & HOUR(LastRefresh[LastRefresh]) &":" &MINUTE(LastRefresh[LastRefresh]) &":"& SECOND(LastRefresh[LastRefresh])

     

    Basically making it a text field.

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 Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 345 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 225

#3
M Bilal Khan Profile Picture

M Bilal Khan 192

Last 30 days Overall leaderboard