Skip to main content

Notifications

Community site session details

Community site session details

Session Id : XDsWivIRp6ZeKCk+40feMy
Power Automate - General Discussion
Answered

Date Display formatDateTime Issues in Loop for Output

Like (0) ShareShare
ReportReport
Posted on 25 Jun 2020 16:46:46 by 203
I'm trying to format my date field for display (basically chop off the time) from a D365 date to put into an email and I'm getting
 
"The expression is invalid." when I try to do this in the Expressions window. The xxxx_notificationdate is in a Apply to Each loop. 
 
formatDateTime(@{items('Apply_to_each')?['xxxx_notificationdate']},'yyyy-MM-dd')
 
What am I doing wrong?
  • Verified answer
    Hardesh15 Profile Picture
    7,087 Super User 2024 Season 1 on 25 Jun 2020 at 16:57:18
    Re: Date Display formatDateTime Issues in Loop for Output

    @saturation 

     

    Please use this-

    formatDateTime(items('Apply_to_each')?['xxxx_notificationdate'],'yyyy-MM-dd')

     

    Thanks

    Hardesh

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

Thomas Rice – Community Spotlight

We are honored to recognize Thomas Rice as our March 2025 Community…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,508 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,440 Most Valuable Professional

Leaderboard
Loading complete