+ Reply to Thread
Results 1 to 6 of 6

convert hh:mm:ss-hh:mm:ss to seconds-seconds

Hybrid View

  1. #1
    Registered User
    Join Date
    10-11-2012
    Location
    Provo, UT
    MS-Off Ver
    Excel 2010
    Posts
    3

    Question convert hh:mm:ss-hh:mm:ss to seconds-seconds

    I am using Excel 2010 and I am trying to convert times shown in the format hh:mm:ss - hh:mm:ss to seconds-seconds. Here is an example, I am doing something with movies, but for editing purposes in need it in seconds instead of the hour:minute:seconds format. For example in need to convert from 00:35:43 - 00:37:10 to 2143 - 2230. Here are are few more examples of what I need to convert to seconds format...
    1:30:13 - 1:33:07
    1:00:09 - 1:02:57
    Does anybody have any idea how I can do this?
    Last edited by lrc_secretary; 10-11-2012 at 11:34 AM.

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,408

    Re: convert hh:mm:ss-hh:mm:ss to seconds-seconds

    Assuming your data is in A2, you can use this formula:

    =LEFT(A2,SEARCH(" -",A2)-1)*60*60*24 &" - "&RIGHT(A2,LEN(A2)-SEARCH("- ",A2)-1)*60*60*24

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    10-11-2012
    Location
    Provo, UT
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: convert hh:mm:ss-hh:mm:ss to seconds-seconds

    Thank you! that solved it for me.

  4. #4
    Registered User
    Join Date
    10-11-2012
    Location
    Provo, UT
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: convert hh:mm:ss-hh:mm:ss to seconds-seconds

    If some of the times were entered as just mm:ss-mm:ss how can I adjust the formula?

  5. #5
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,408

    Re: convert hh:mm:ss-hh:mm:ss to seconds-seconds

    It's a bit messy, but you could do this:

    =LEFT(A2,SEARCH(" -",A2)-1)*if(len(LEFT(A2,SEARCH(" -",A2)-1))<=5),1,60)*60*24 &" - "&RIGHT(A2,LEN(A2)-SEARCH("- ",A2)-1)*if(len(RIGHT(A2,LEN(A2)-SEARCH("- ",A2)-1))<=5,1,60)*60*24

    Hope this helps.

    Pete

  6. #6
    Forum Expert ConneXionLost's Avatar
    Join Date
    03-11-2009
    Location
    Victoria, Canada
    MS-Off Ver
    2010
    Posts
    2,952

    Re: convert hh:mm:ss-hh:mm:ss to seconds-seconds

    Another way:

    =TEXT(TIMEVALUE(TRIM(LEFT(A2,8))),"[ss]")&" - "&TEXT(TIMEVALUE(TRIM(RIGHT(A2,8))),"[ss]")
    Would you like to say thanks? Please click the: " Add Reputation" button, on the grey bar below the post.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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