+ Reply to Thread
Results 1 to 4 of 4

format time

  1. #1
    Forum Contributor
    Join Date
    11-10-2013
    Location
    London, England
    MS-Off Ver
    Excel 2010
    Posts
    260

    format time

    anyone know how to format column B to have time in HH:MM:SS? i tried with custom but no way... any help? i'm going crazy
    Attached Files Attached Files

  2. #2
    Forum Expert 63falcondude's Avatar
    Join Date
    08-22-2016
    Location
    USA
    MS-Off Ver
    365
    Posts
    6,266

    Re: format time

    I would use a formula to convert the times.

    Try this:
    J2 =TIME(LEFT(B2,2),MID(B2,3,2),RIGHT(B2,2))
    or this:
    =--TEXT(B2,"00\:00\:00")

    You should also convert column A to actual dates.
    To do this, highlight column A > Data > Text to Columns > Next > Next > Date: DMY > Finish
    Last edited by 63falcondude; 10-24-2017 at 01:06 PM. Reason: Added second formula

  3. #3
    Valued Forum Contributor
    Join Date
    07-17-2005
    Location
    Abergavenny, Wales, UK
    MS-Off Ver
    XL2003, XL2007, XL2010, XL2013, XL2016
    Posts
    608

    Re: format time

    In another column on your sheet, enter the following formula
    =LEFT(B2,2)&":"&MID(B2,3,2)&":"&RIGHT(B2,2)

    Now Format column B as HH:MM:SS
    Copy the data from your new column, and Paste Values back to column B
    They will now be stored as true times which you can prove by entering in another cell =B2+1/24 and you will get a time wch is 1 hour greater 17:10:36

    You can't make time entries to a cell as 161036, you have to enter as 16:10:36
    --
    Regards
    Roger Govier
    Microsoft Excel MVP

  4. #4
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (both in England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2503 (Windows 11 Home 24H2 64-bit)
    Posts
    90,568

    Re: format time

    Just in case it's relevant: none of this is going to resolve the mismatch issue I flagged in your commercial services thread earlier.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help. It's a universal courtesy.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    NB:
    as a Moderator, I never accept friendship requests.
    Forum Rules (updated August 2023): please read them here.

+ 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. VBA calculate sleep time, when time is entered in military time format
    By axm1955 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 09-29-2017, 10:28 AM
  2. [SOLVED] time sheet help, format TIME and formula based on the actual time entered.
    By bh mng in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 12-06-2016, 01:10 PM
  3. Format time from military time to standard time
    By Valencia0307 in forum Excel General
    Replies: 7
    Last Post: 06-01-2014, 11:15 AM
  4. Change format of lots of data cell to a time format
    By dazza67 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 03-24-2013, 03:24 PM
  5. Convert date and time in serial number format to text format
    By nda13112 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-11-2013, 02:45 PM
  6. Excel: How to convert time format into number format that can be added?
    By Frances Jones in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-17-2012, 04:10 PM
  7. Display time in time format instead of decimal format
    By CasualVisitor in forum Excel General
    Replies: 5
    Last Post: 07-03-2009, 06:24 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