+ Reply to Thread
Results 1 to 5 of 5

Time format question

  1. #1
    Registered User
    Join Date
    10-04-2005
    Posts
    73

    Time format question

    Hi All

    I would like to undestand why I am getting a different result in excel based upon the time format. I have attached an image of my spreadsheet and also the excel file so you can see what I mean.

    img.JPG

    Sounds simple right....that's what I thought but can't seem to figure out what's happening.

    Thanks for your help.

    Time example.xls

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Time format question

    The actual number in E11 is 9.26458333304618
    (change to General format to see that)

    Each whole number represents a full day to Excel in "date formatting". So 1 = 1 day, 2 = 2 days, etc. So that number represents 9 days plus a fraction of a day.

    The [h]:mm Time format represent all days as a count of the HOURS. So 9 days = 9x24, plus the fraction of a day, = 222 hours and 21 minutes.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    10-04-2005
    Posts
    73

    Re: Time format question

    Hi JBeaucaire

    Thanks for your reply. I do not understand why I get a result of 06:21 when the hh:mm format and 221:21 when using the [hh]:mm format.

    Surely I should return the same results using either format?

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Time format question

    h:mm gives the time (the residual portion of a day). The square brackets around the h instead displays total hours. Likewise, [m] would show total minutes, and [s] total seconds.
    Entia non sunt multiplicanda sine necessitate

  5. #5
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Time format question

    If you now understand fully the difference between [h] (includes days) and h (ignores days), please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ 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. [SOLVED] Time Format Question
    By Bob Phillips in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-06-2005, 04:05 AM

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