+ Reply to Thread
Results 1 to 8 of 8

Time stored as text. How can I convert to data and time?

  1. #1
    Registered User
    Join Date
    08-28-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2010
    Posts
    5

    Time stored as text. How can I convert to data and time?

    Hi, I thought I could do this...but it's driving me bananas!

    I've have a column of a report that's for telephone call duration, but the information is left aligned/text.

    Is there a formula I could use to convert this to data?

    Thanks in advance.

    Matthew


    Duration
    0:00:45
    0:02:16
    0:00:19
    0:06:31
    0:05:50
    0:04:03
    0:04:30
    0:02:17
    0:27:45
    0:06:41
    0:00:26
    0:00:52
    0:00:38
    0:00:55
    0:02:21
    0:04:14
    0:05:10
    0:02:15
    0:02:16
    0:01:27
    0:10:18
    0:01:24
    0:08:24
    0:04:14
    0:00:21
    0:00:38
    0:00:26
    0:00:53
    0:17:01

  2. #2
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time stored as text. How can I convert to data and time?

    Select the column
    Data ribbon - text to columns - Finish

  3. #3
    Registered User
    Join Date
    08-28-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Time stored as text. How can I convert to data and time?

    Hi Arthur,

    First of all, thank you!

    I'd tried that route, but then became flummoxed because I had my minutes data in one column and seconds in the next..I'm still flummoxed to be honest.

    It looks like this:

    Duration
    0 0 45
    0 2 16
    0 0 19
    0 6 31
    0 5 50
    0 4 3
    0 4 30
    0 2 17
    0 27 45

    How can I get it so instead that date is in one column, like this:

    00:00:45
    00:02:16
    00:00:19
    etc

    Thank again,

    Matthew.

  4. #4
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Time stored as text. How can I convert to data and time?

    That is why posting a sheet is much easier...

    Anyway try =(a1&":"&a2&":"&a3)*1

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

    Re: Time stored as text. How can I convert to data and time?

    I think Arther means

    =(a1&":"&b1&":"&c1)*1

    In any case, his first instructions should have worked and not split your data into different columns. Maybe go through the different text to columns screens to make sure it is not separating your data and formatting as general. You will then need to go in and reformat as time.

    As Arthur also said, it's easier with an example sheet (Go Advanced>Manage Attachments)
    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

  6. #6
    Registered User
    Join Date
    08-28-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Time stored as text. How can I convert to data and time?

    To you both, thank you. In future I will include sheets, I can see how this makes more sense, sorry.

    I've just tried the text to columns method again. I (idiot) used a colon as the delimiter and that's why it separated out.

    But I've just tried the straight highlight column > data ribbon > text to columns > finish (without pressing next) and the text seems to remain as text, left aligned and I can't use it to sum etc. Any ideas?

    Thanks.

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

    Re: Time stored as text. How can I convert to data and time?

    Yes, can you check for invisible characters (i.e spaces) in front of or behind the times? In the formula bar, you should be able to place the cursor before or after the text to see if there are extra characters there.

    To remove these characters (which might automatically reset your text to numbers) copy the invisible character into the Find/Replace window (shortcut CNTRL H) and replace with nothing, replace all.

  8. #8
    Registered User
    Join Date
    08-28-2012
    Location
    United Kingdom
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Time stored as text. How can I convert to data and time?

    Boom! I'm on my way. Many thanks for your help folks!

+ 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