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 / Calculated field-Diffi...
Power Apps
Unanswered

Calculated field-Diffindate

(0) ShareShare
ReportReport
Posted on by 375

I have a date field (calculated field) called IR Due Date. I want to calculate the difference between Start Date and End Date. 

 

What is the correct function syntax for this? 

 

IR Due Date=End Date-Start Date

 

I have tried DIFFINDAYS but i want the return type to be date. 

 

 

Categories:
  • WarrenBelz Profile Picture
    156,532 Most Valuable Professional on at

    Hi @NurNina ,

    The result will be numeric (the number of days between them)

    DateDiff(
     StartDate,
     EndDate,
     Days
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

     

  • NurNina Profile Picture
    375 on at

    Hi @WarrenBelz , Is this solution for calculated field? Cos it seems that there is no DateDiff function. 

     

    NurNina_0-1609830333354.png

     

  • timl Profile Picture
    37,287 Super User 2026 Season 2 on at

    Hi @NurNina 

    For a Dataverse calculated field, the DIFFINDAYS function that you mentioned would be the one to use.

    DIFFINDAYS (EndDate,StartDate)

    This would return a numeric value of the difference in days.

    The other available functions include:

    DIFFINHOURS, DIFFINMINUTES, DIFFINMONTHS, DIFFINWEEKS, DIFFINYEARS

    I'm not sure what you mean when you say that you want to return type to be date. Can you clarify what you mean by this?

    For example, let's assume a start date of 1 Jan 2021, and an end date of 3 Jan 2021. What would a date representation of a two-day difference look like, or what would you like the IR Due Date value to look like this example? Are you saying that you want to add the difference to the EndDate like so?

    ADDDAYS(DIFFINDAYS (EndDate,StartDate), EndDate)
  • WarrenBelz Profile Picture
    156,532 Most Valuable Professional on at

    @NurNina ,

    If you had mentioned your data source, it would have helped. DateDiff certainly is a function of Canvas Apps.

    If you have a time, this document on helpful things to post may be useful.

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 411 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 338

#3
WarrenBelz Profile Picture

WarrenBelz 256 Most Valuable Professional

Last 30 days Overall leaderboard