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

yesterday's date

I was given the following expression to add today's date under a certain format

 

formatDateTime(utcNow(),'MM-dd-yyyy')
 
How do I make the same but for yesterday's date? because I always get the paper the next morning and its for the day before

Regards
 
1 ACCEPTED SOLUTION

Accepted Solutions
RobElliott
Super User
Super User

@Towaiji  

 

formatDateTime(addDays(utcNow(),-1),'MM-dd-yyyy')

 

Rob
Los Gallardos
If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.

View solution in original post

1 REPLY 1
RobElliott
Super User
Super User

@Towaiji  

 

formatDateTime(addDays(utcNow(),-1),'MM-dd-yyyy')

 

Rob
Los Gallardos
If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.

Helpful resources

Announcements
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.

Difinity Conference 2022

Difinity Conference 2022

Register today for two amazing days of learning, featuring intensive learning sessions across multiple tracks, led by engaging and dynamic experts.

European SharePoint Conference

European SharePoint Conference

The European SharePoint Conference returns live and in-person November 28-December 1 with 4 Microsoft Keynotes, 9 Tutorials, and 120 Sessions.

Users online (4,542)