Results 1 to 10 of 10

Convert Hours minutes and Kilometer text values to numeric

Threaded View

  1. #1
    Registered User
    Join Date
    09-09-2021
    Location
    London, Ontario, Canada
    MS-Off Ver
    Office 365
    Posts
    56

    Convert Hours minutes and Kilometer text values to numeric

    Good Morning,

    I was wondering if someone can help me with this data output.
    Each day a human will manually export the data and paste it into a spreadsheet then add the date to column A. Then the next day they will paste the newly exported records at the bottom of the list. This will continue day after day and year over year.
    I was hoping someone would have a macro solution they could run after pasting the data each day that loops through the records and does the conversions.

    I have a little bit of VBA understanding. If the code could be commented so I can maintain it if necessary, I would appreciate that.

    I originally started doing this with formulas but, after some discussion with the end users, by the end of the year this could have over 100,000 rows, pivot table reports and formulas. They want to use this for a year over year reporting so after a few years we could be looking at 100K rows every year.
    I figured that would make this workbook very slow. I realize that even after a couple years this might not be optimal. Excel is their only option at present.

    Basically what I am looking for is a way to convert the values in columns D, E, F, H from hours and minutes text value to the rounded off numeric value of total minutes.
    The values from the export look like this along with what I would like it converted to:
    ( i did notice that values with minutes only are 9 characters long and values with Hours and minutes are 16. It never varies 9 or 16)

    "01 hrs 23.00 min" convert to 83
    "41.24 min" convert to 41
    "23.50 min" convert to 24
    "01 hrs 28.21 min" convert to 88

    Likewise column "i" will need to be converted to just the rounded kilometer number.

    "157.56 km" convert to 158
    "0 km" convert to 0
    "202.67 km" convert to 203
    "68.67 km" convert to 69

    Please let me know if you require further clarification.
    I really appreciate everyone's time and input on this matter.
    Attached Files Attached Files
    Last edited by GrayWolf; 07-13-2022 at 09:21 AM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Convert text to hours/minutes/seconds
    By JacobH123 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 04-12-2021, 10:14 AM
  2. [SOLVED] Convert text Days, hours, minutes to total hours.
    By Hyperion1571 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-02-2021, 04:06 PM
  3. Replies: 3
    Last Post: 09-21-2015, 01:56 PM
  4. Excel 2007 : Convert number of minutes to hours and minutes
    By MikeFromIndy in forum Excel General
    Replies: 30
    Last Post: 06-05-2015, 08:10 AM
  5. Convert Hours, day and week values in minutes
    By jonyorker in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-02-2015, 03:28 PM
  6. Convert Days:Hours:Minutes:seconds to minutes.
    By Kevingardner1 in forum Excel General
    Replies: 4
    Last Post: 06-03-2014, 06:44 PM
  7. Replies: 5
    Last Post: 06-22-2006, 10:10 PM

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