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 / Como Restar fechas ?
Power Apps
Unanswered

Como Restar fechas ?

(0) ShareShare
ReportReport
Posted on by 53

 

Saludos tengo una pequeña app en la que necesito restar 2 fechas. pero no logro obtener en resultado deseado.

Puedo capturar las fechas pero en la operación de la restas no obtengo el resultado.

Los datos se almacenan en Excel.

 

JosueCR_1-1612798004362.png

 

 

 

 Text(FechaRevisa.SelectedDate + Time(
 Value(HourRevisa.Selected.Value);
 Value(MinuteRevisa.Selected.Value);
 0
 )))-(Text(FechaRecibe.SelectedDate + Time(
 Value(HourRecibe.Selected.Value);
 Value(MinuteRecibe.Selected.Value);
 0
 )))

 

 

 

Categories:
I have the same question (0)
  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    Hola @JosueCR 

    Use the DateDiff() function.  The Syntax is DateDiffStartDateTimeEndDateTime [, Units ] ).  The units default to Days but Minutes, Hours, Months, Quarters, or Years can be used intead.

  • JosueCR Profile Picture
    53 on at

    @Drrickryp wrote:

    Hola @JosueCR 

    Use the DateDiff() function.  The Syntax is DateDiffStartDateTimeEndDateTime [, Units ] ).  The units default to Days but Minutes, Hours, Months, Quarters, or Years can be used intead.



    @Drrickryp wrote:

    Hola @JosueCR 

    Use the DateDiff() function.  The Syntax is DateDiffStartDateTimeEndDateTime [, Units ] ).  The units default to Days but Minutes, Hours, Months, Quarters, or Years can be used intead.


    (DateDiff(FechaRecibe.SelectedDate+Time(Value(HourRecibe.Selected.Value);Value(MinuteRecibe.Selected.Value);0);FechaRevisa.SelectedDate+Time(Value(HourRevisa.Selected.Value);Value(MinuteRevisa.Selected.Value);0);Minutes))

     

    logre hacerlo pero obtengo el resultado en segundos... como puedo pasarlo a formato Hh:Mm

    horas y minutos?

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @JosueCR 

    Try

    Text(RoundDown(DateDiff(CurrentTime,InitialTime,Seconds)/3600,0),"00")&":"&
    Text(If(RoundDown(DateDiff(CurrentTime,InitialTime,Seconds)/60,0)>59,0,RoundDown(DateDiff(CurrentTime,InitialTime,Seconds)/60,0)),"00")&":"&
    Text(Mod(DateDiff(CurrentTime,InitialTime,Seconds),60),"00")
  • JosueCR Profile Picture
    53 on at

    Gracias,

    Pero tu respuesta me dejo mas confundido de lo que ya estaba. 😥

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    Lo siento mucho!!Lo siento mucho!!

     

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 401 Most Valuable Professional

#2
11manish Profile Picture

11manish 201 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 128 Super User 2026 Season 2

Last 30 days Overall leaderboard