+ Reply to Thread
Results 1 to 5 of 5

Subtracting Dates to Show Hours Spanning Multiple Days

  1. #1
    Registered User
    Join Date
    08-04-2016
    Location
    Newcastle, England
    MS-Off Ver
    365
    Posts
    7

    Subtracting Dates to Show Hours Spanning Multiple Days

    Hi all,

    As it says above really; I am looking for a way to subtract date time stamps and show the result in hh:mm:ss.

    COLUMN A COLUMN B COLUMN C
    01/01/2016 10:10:53 05/01/2016 11:49:25 =B1-B2

    In C1 I get 01:38:32.

    C1 is formatted to show hh:mm:ss -- so it is doing the calculation right.
    If I change the format of the cell to dd/mm/yyyy hh:mm:ss; the result in C1 is now 04/01/1990 01:38:32

    So, how do I make it perform the deduction and show 97:38:32 ??

    I have tried converting to days, subtracting and *24 then adding to time; but (1) its ugly and messy & (2) it falls down at the end of a calendar month/year and gets even uglier and messier.

    Any help greatly appreciated

    Cheers

    Andy

  2. #2
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Subtracting Dates to Show Hours Spanning Multiple Days

    Format the cell as [h]:mm:ss

    The brackets [ ] keep the hours from rolling over into days.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  3. #3
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,196

    Re: Subtracting Dates to Show Hours Spanning Multiple Days

    Format as

    [h]:mm:ss

  4. #4
    Registered User
    Join Date
    08-04-2016
    Location
    Newcastle, England
    MS-Off Ver
    365
    Posts
    7

    Re: Subtracting Dates to Show Hours Spanning Multiple Days

    Both, thanks very very much.

  5. #5
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Subtracting Dates to Show Hours Spanning Multiple Days

    You're welcome!

+ 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. Counting days between two dates which a day is 7.5 hours
    By Ginette Lacombe in forum Hello..Introduce yourself
    Replies: 1
    Last Post: 07-07-2016, 11:25 AM
  2. Gantt in Excel spanning over 3 days with hours
    By juverma in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-25-2014, 02:54 PM
  3. [SOLVED] what format to use to show days in hours
    By wayneg in forum Excel General
    Replies: 2
    Last Post: 11-22-2012, 10:33 AM
  4. Hours in gnatt spanning midnight
    By r1ch1nxdcc in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-15-2009, 10:22 AM
  5. Days & Hours B/t Two Dates & Times
    By Grock258 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 05-27-2009, 11:54 AM
  6. get hours between 2 dates subtracting the weekends
    By Cynthia in forum Excel General
    Replies: 4
    Last Post: 05-11-2006, 03:00 PM
  7. Replies: 2
    Last Post: 10-05-2005, 01:20 PM

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