+ Reply to Thread
Results 1 to 5 of 5

Text to minutes conversion

  1. #1
    Registered User
    Join Date
    05-10-2013
    Location
    Auckland
    MS-Off Ver
    Excel 2007
    Posts
    3

    Text to minutes conversion

    I have a file which contains time in any one of these formats:
    • 1d 1hr 4m 59s
    • 2hr 21m 20s
    • 17m 41s
    • 31s

    I am trying to convert these strings to minutes and I have nor been to successfull with my attempts.

    Any suggestions or guidance is apprecited.

    KiwiGreg

  2. #2
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,180

    Re: Text to minutes conversion

    one way would be to use a UDF (user defined function)

    Please Login or Register  to view this content.
    Cheers
    Andy
    www.andypope.info

  3. #3
    Registered User
    Join Date
    05-10-2013
    Location
    Auckland
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Text to minutes conversion

    Andy, thank you for your UDF example.

    If you take 1d 1hr 4m 59s rounded up this equqtes to 1505 minutes (this is what I need to convert the string to). The function returns 1.045127.

    Can you please modify it to reflect the minutes.

    Apologies if I have missed something.

  4. #4
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,180

    Re: Text to minutes conversion

    The value returned is the way excel stores date values.

    By simply changing the number format you can alter the way it is displayed.

    If you want to roundup you will need to search the forum for the correct formula to do that.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    05-10-2013
    Location
    Auckland
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Text to minutes conversion

    Thanks for the help Andy. You have lust made my life a whole lot easier.

+ 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