+ Reply to Thread
Results 1 to 9 of 9

calculate duration

  1. #1
    Forum Contributor
    Join Date
    07-06-2013
    Location
    Borneo
    MS-Off Ver
    2016
    Posts
    277

    calculate duration

    dear expert

    I've in A1 "08/04/2016 08:00" and in B1 "08/04/2016 10:30"
    and I need to know how long the duration from A1 to B1?

    Some time a1 and b1 have different date
    Last edited by azbi; 05-31-2016 at 09:18 PM.

  2. #2
    Forum Contributor amit.wilson's Avatar
    Join Date
    07-09-2013
    Location
    Gotham
    MS-Off Ver
    Excel for Mac 2011
    Posts
    283

    Re: calculate duration

    Azbi,

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    will give you the difference between the two dates/times. You can then format the output correctly to show it in hours and minutes.

    Cheers
    <-- If you're happy & you know it...click the star.:-)

  3. #3
    Forum Contributor
    Join Date
    07-06-2013
    Location
    Borneo
    MS-Off Ver
    2016
    Posts
    277

    Re: calculate duration

    sorry amit.wilson, your formula could be use in same date only, not for different date

  4. #4
    Forum Contributor amit.wilson's Avatar
    Join Date
    07-09-2013
    Location
    Gotham
    MS-Off Ver
    Excel for Mac 2011
    Posts
    283

    Re: calculate duration

    Try
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    And format the cell as Custom-->hh:mm

    Cheers

  5. #5
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: calculate duration

    Quote Originally Posted by azbi View Post
    sorry amit.wilson, your formula could be use in same date only, not for different date
    No, you just need to format it correctly. B1-A1 will show you the difference btw those cells, no matter what it is
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  6. #6
    Forum Guru
    Join Date
    04-13-2005
    Location
    North America
    MS-Off Ver
    2002/XP, 2007, 2024
    Posts
    16,415

    Re: calculate duration

    I would suggest this help file (one of the help files I used the most) https://support.office.com/en-us/art...fab54be7f4#bm1
    Note in particular the time formatting about 2/3 of the way down. Note the difference between time hh:mm and elapsed time [hh]:mm.
    Quote Originally Posted by shg
    Mathematics is the native language of the natural world. Just trying to become literate.

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: calculate duration

    MrShorty, very helpful link - added to my collection

  8. #8
    Forum Contributor
    Join Date
    07-06-2013
    Location
    Borneo
    MS-Off Ver
    2016
    Posts
    277

    Re: calculate duration

    after read article from MrShorty, and thinking deeply about what was FDibbins wrote, I tried to use amit.wilson and change the format, and finally I've got what I want
    thanks for you all who has make me understand

  9. #9
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: calculate duration

    Good stuff, Im glad you got it resolved, and thanks for the feedback

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Calculate a limited duration
    By Johnny Image in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-25-2013, 10:47 AM
  2. [SOLVED] Formula: To calculate duration between two times, if duration is over 6hours subtract 30mi
    By MattBarnes7 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-11-2013, 03:22 PM
  3. Calculate Duration & Resources
    By mycon73 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 08-08-2012, 03:49 PM
  4. calculate shift duration
    By jeffbrown1966 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-29-2010, 09:13 AM
  5. calculate duration of hours
    By winco32 in forum Excel General
    Replies: 2
    Last Post: 11-09-2008, 06:43 AM
  6. How to calculate duration of time
    By annlanding in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-11-2006, 12:38 PM
  7. Calculate Duration.
    By Art in forum Excel General
    Replies: 6
    Last Post: 09-04-2005, 09:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1