+ Reply to Thread
Results 1 to 4 of 4

.txt Clock file to XLS - Difficult

  1. #1
    Registered User
    Join Date
    03-30-2014
    Location
    South Africa
    MS-Off Ver
    Excel 2010
    Posts
    63

    Post .txt Clock file to XLS - Difficult

    HI There

    I need some advise in the import of data to xls.

    Attached is the .txt file I get from out Clocking System, now we have to by hand subtract the new time and the old time to see how long someone took a break. Now I have tried VARIOUS ways, but seems to come out a mess every-time to rework it in xls.

    for example:

    0708 : 0737 means that the person clocked in at 07:08 and clocked out at 0737

    Then when there is a "x" after a time, it means it was booked beck into the system
    The * means the time was manually added in

    Is there a way to extract the times (4 numbers) only and then convert them to time format...I will then do the time subtractions afterwards
    Attached Files Attached Files

  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,218

    Re: .txt Clock file to XLS - Difficult

    I imported your data into Excel and then put this formula in cell N4:

    =IF($D4="","",IFERROR((MID(SUBSTITUTE(SUBSTITUTE(":"&$D4&":","x",""),"*",""),FIND(":",SUBSTITUTE(SUBSTITUTE(":"&$D4&":","x",""),"*",""),(COLUMNS($N:N)-1)*5+1)+1,2)&":"&MID(SUBSTITUTE(SUBSTITUTE(":"&$D4&":","x",""),"*",""),FIND(":",SUBSTITUTE(SUBSTITUTE(":"&$D4&":","x",""),"*",""),(COLUMNS($N:N)-1)*5+1)+3,2)&":00")*1,""))

    This can be copied across and down as required, and turns each of the numbers into the appropriate time in Excel format (blue cells).

    Hope this helps.

    Pete
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    03-30-2014
    Location
    South Africa
    MS-Off Ver
    Excel 2010
    Posts
    63

    Re: .txt Clock file to XLS - Difficult

    Ahh WOW - Yes Surly I would NOT have solved this on my OWN!! THANKS A LOT!!

    When you imported the data, you just had it on Fixed width and "next-ed" it and finish -No other settings?

    Once again THANK YOU SO MUCH!!YOU MADE MY DAY

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

    Re: .txt Clock file to XLS - Difficult

    I clicked Finish on the first panel, so I didn't change any of the default settings.

    Glad it worked for you.

    Pete

+ 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. Clock In/ Clock out macro
    By DevonH in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 06-11-2019, 01:33 PM
  2. [SOLVED] Calculating Allocated Hours Based On Clock In and Clock Out
    By rahul_ferns76 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 05-15-2016, 07:46 AM
  3. VBA or Macro to Help with clock in/Clock out
    By kwd114 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-09-2015, 02:19 PM
  4. Replies: 2
    Last Post: 12-20-2013, 12:12 AM
  5. Clock in/Clock out calculation
    By phatpandas in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-19-2007, 03:23 PM
  6. *difficult* importing slection from a txt file to new column
    By Trogent in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-19-2005, 12:05 AM
  7. Start Clock/Stop Clock
    By abfabrob in forum Excel General
    Replies: 9
    Last Post: 06-28-2005, 12:05 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