+ Reply to Thread
Results 1 to 10 of 10

Remove part of pasted information in cells?

  1. #1
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Remove part of pasted information in cells?

    Hi everyone!

    Im trying to get a sheet to automatically fill in based on the raw data i paste into other sheets. this part is not a big issue but the issue is that in one of the raw data columns the time stamp is not for example "08:09:12" like a regular one, Its "08:09:12sec".

    Is there any formula that I can add to a column that will automatically remove the "sec" part which would then make it possible to add other values to get a total amount of time? or will i manually have to remove the "sec" everytime?

    Thank you in advance!

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Remove part of pasted information in cells?

    try this...

    =LEFT(A1,LEN(A1)-3)*1
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Re: Remove part of pasted information in cells?

    Hi, Not sure how to implement that part. The current one im running is:

    Please Login or Register  to view this content.
    How can I implement that line into what you wrote?

  4. #4
    Valued Forum Contributor
    Join Date
    10-29-2012
    Location
    Mojokerto,Indonesia
    MS-Off Ver
    Excel 2007
    Posts
    554

    Re: Remove part of pasted information in cells?

    if data at A1 formula at B1

    =SUBSTITUTE(A1,"sec";"")

  5. #5
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Re: Remove part of pasted information in cells?

    Hmm, Im very new to Excel and programming so not sure HOW to implement that either if im honest

    I tried setting it straight into the cell but then I dont know how to grab my value and If i set it in another cell then the line just comes back as not working.

  6. #6
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Re: Remove part of pasted information in cells?

    Heres an example file.
    example file.xlsx

    Typed in 2 values as regularly which works fine and then 2 values with the sec text added to it. This is the kind of file I want to use but Im not sure on how to get it to work.

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Remove part of pasted information in cells?

    you have an extra space at the end of some of the entries. try this version instead...
    =LEFT(A1,LEN(TRIM(A1))-3)*1

  8. #8
    Valued Forum Contributor
    Join Date
    10-29-2012
    Location
    Mojokerto,Indonesia
    MS-Off Ver
    Excel 2007
    Posts
    554

    Re: Remove part of pasted information in cells?

    use array formula

    {=SUM(--SUBSTITUTE(A1:D1;"sec";""))}

    see this attachment

  9. #9
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Re: Remove part of pasted information in cells?

    IT WORKS! Thank you so much!

  10. #10
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Remove part of pasted information in cells?

    not sure which 1 worked, but we are happy to help. please consider adding the reputation to those that helped (see point 3 below)

+ 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