+ Reply to Thread
Results 1 to 7 of 7

Help with Text string

  1. #1
    Registered User
    Join Date
    05-19-2004
    Posts
    34

    Help with Text string

    I have a column of data that consists of an 8 digit alpha/numeric code followed by 2 spaces followed by a description. For example:
    "ABCD123A Text text text"

    I would like to extract the code (removing the 2 spaces at the end) into its own column leaving just the description in its own column.

    So "ABCD123A Text text text" becomes "ABCD123A" in one column and "Text text text" in the next column.

    Any help or tips would be very much appreciated.

  2. #2
    Forum Moderator zbor's Avatar
    Join Date
    02-10-2009
    Location
    Croatia
    MS-Off Ver
    365 ProPlus
    Posts
    15,592

    Re: Help with Text string

    Here, try this:
    Attached Files Attached Files

  3. #3
    Forum Expert
    Join Date
    07-16-2010
    Location
    Northumberland, UK
    MS-Off Ver
    Excel 2007 (home), Excel 2010 (work)
    Posts
    3,054

    Re: Help with Text string

    If your data is in column A, starting at row 2 then in B2 put:

    =LEFT(A2,8)

    And in C2 put:

    =MID(A2,11,255)

    Then copy down.

  4. #4
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Help with Text string

    Or do find and replace for two spaces, replace it with something like |

    Then do text to columns on |

  5. #5
    Forum Guru (RIP) Marcol's Avatar
    Join Date
    12-23-2009
    Location
    Fife, Scotland
    MS-Off Ver
    Excel '97 & 2003/7
    Posts
    7,216

    Re: Help with Text string

    @ Kyle
    If you want to use Text to Colums, why not just use the "Fixed Width" option with a column break after the 8th character and another before the text?
    You can choose to skip the blank column in between.
    If you need any more information, please feel free to ask.

    However,If this takes care of your needs, please select Thread Tools from menu above and set this topic to SOLVED. It helps everybody! ....

    Also
    اس کی مدد کرتا ہے اگر
    شکریہ کہنے کے لئے سٹار کلک کریں
    If you are satisfied by any members response to your problem please consider using the small Star icon bottom left of their post to show your appreciation.

  6. #6
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Help with Text string

    Yep, that'd work, just don't like fiddling around with break lines, I always add them when I'm double clicking and it annoys me

  7. #7
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Help with Text string

    dont get click happy,use mouse dicipline! lol
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

+ 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