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 / DateDiff Days Hours Mi...
Power Apps
Answered

DateDiff Days Hours Minutes

(0) ShareShare
ReportReport
Posted on by 23

Hello again,I’m struggling with a DateDiff funciton. I have two dates with hours and minutes values. I want to check how many hours of difference there is and divide it by 24 hours, get a number of days left and spare hours which will be used later on.

DateValue1

HourValue1

MinuteValue1

DateValue2

HourValue2

MinuteValue2

Capture.PNG
Categories:
I have the same question (0)
  • Verified answer
    mdevaney Profile Picture
    29,991 Moderator on at

    @Draqon 

    Days between

    RoundDown(DateDiff(DateValue2.SelectedDate + Time(HourValue2.Selected.Value, MinuteValue2.Selected.Value,0), DateValue1.SelectedDate + Time(HourValue1.Selected.Value, MinuteValue1.Selected.Value,0), Days),0)

     

    Spare hours

    RoundDown(Mod(DateDiff(DateValue2.SelectedDate + Time(HourValue2.Selected.Value, MinuteValue2.Selected.Value,0), DateValue1.SelectedDate + Time(HourValue1.Selected.Value, MinuteValue1.Selected.Value,0), Hours), 24),0)

     

    Spare minutes

    RoundDown(Mod(DateDiff(DateValue2.SelectedDate + Time(HourValue2.Selected.Value, MinuteValue2.Selected.Value,0), DateValue1.SelectedDate + Time(HourValue1.Selected.Value, MinuteValue1.Selected.Value,0), Minutes), 60),0)

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

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
WarrenBelz Profile Picture

WarrenBelz 400 Most Valuable Professional

#2
11manish Profile Picture

11manish 141 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 109 Super User 2026 Season 2

Last 30 days Overall leaderboard