cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper III
Helper III

Date and Time Value Syntax

I'm trying to put a long date format on a label.  LblExpiry.Text The label default is currently

 

If(IsBlank(ThisItem.ExpiryDate),CalcExpiry.SelectedDate,ThisItem.ExpiryDate)

 Which shows up like this   10/28/2020

 

I would like it to show like this..  Thursday, October 28, 2020   

 

so I have a workaround where I add a new label and put this in the default

 

Text(DateValue(LblExpiry.Text),DateTimeFormat.LongDate)

 

that's fine except it adds an extra label that I don't really want I would prefer to have LblExpiry.Text show in the correct way, but I've tried putting the Text(DateValue etc.. at various sections but can't get it right !

 

TIA

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Super User III
Super User III

Update your code to:

 

Text(If(IsBlank(ThisItem.ExpiryDate),CalcExpiry.SelectedDate,ThisItem.ExpiryDate),DateTimeFormat.LongDate)

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

View solution in original post

2 REPLIES 2
Super User III
Super User III

Update your code to:

 

Text(If(IsBlank(ThisItem.ExpiryDate),CalcExpiry.SelectedDate,ThisItem.ExpiryDate),DateTimeFormat.LongDate)

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

View solution in original post

Perfect thanks 🙂

Helpful resources

Announcements
News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

Power Apps Community Call

Power Apps Community Call- January

Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST

PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

Top Solution Authors
Top Kudoed Authors
Users online (10,822)