+ Reply to Thread
Results 1 to 8 of 8

How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

Hybrid View

  1. #1
    Registered User
    Join Date
    05-18-2012
    Location
    MICHIGAN, USA
    MS-Off Ver
    Excel 2003
    Posts
    6

    How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    I've seen response here that say to use [h]:mm:ss but I don't know what I'm doing. How is the forumla supposed to look using cells b17 and b16.

    Thank you

  2. #2
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,327

    Re: How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    Quote Originally Posted by VICTORIE View Post
    I've seen response here that say to use [h]:mm:ss but I don't know what I'm doing. How is the forumla supposed to look using cells b17 and b16.

    Thank you
    [h]:mm:ss is a custom format which would be applied to the result cell. It will allow for times past 24 hours.
    HTH
    Regards, Jeff

  3. #3
    Registered User
    Join Date
    05-18-2012
    Location
    MICHIGAN, USA
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    Thanks for your quick response

    I am trying to calculate production time, the difference between two cells. I was able to do so easily using =MINUTES(b17-b16) but sometimes the difference in time is greater than 59 minutes so I would like to see the hours and minutes displayed. How would I format that?

  4. #4
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    Assuming B17 and B16 are times.

    =B17-B16 should work. Then format your cells (right click> Format Cells) to Custom hh:mm should work unless, as mentioned earlier, it can be more than 24 hours.
    Does that work for you?
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  5. #5
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,327

    Re: How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    What do you have in B17 and B16?

    On a test I did...

    B17 = 5:00:00 AM
    B16 = 6:11:00 AM

    Formula >> B17 - B16 >> formated as h:mm:ss >> produces 1:11:00

    Sorry ChemistB, I did not refresh to see your post...

  6. #6
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    No apologies necessary. I'm usually the slow man on the respond button.

  7. #7
    Registered User
    Join Date
    05-18-2012
    Location
    MICHIGAN, USA
    MS-Off Ver
    Excel 2003
    Posts
    6

    Re: How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    Thanks to you both, it is working exactly the way I wanted it to. I am so glad you guys are here to help!

    Have a great weekend

  8. #8
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,327

    Re: How to display hours, minutes, seconds when subtracting cell b16 time from cell b17

    We are glad to help.

    Thanks for the feedback and hope you have a Happy & Healthy weekend yourself

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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