Thanks Thanks:  0
Likes Likes:  0
Results 1 to 4 of 4

Thread: Extract text before first forward slash

  1. #1
    Board Regular
    Join Date
    Jan 2005
    Posts
    311
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default Extract text before first forward slash

    XP
    Excel 2003

    I have cells showing text data like this:
    BD/JOHNSON&COELHA/CF#WQ8J5D
    CXLD/DUTHCER/523342

    I want to extract the varying length characters strings from left to right before the first forward slash only.

    Thanks for the help

  2. #2
    Board Regular
    Join Date
    Sep 2008
    Location
    Brisbane, Australia
    Posts
    767
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default Re: Extract text before first forward slash

    Quote Originally Posted by isadoko View Post
    XP
    Excel 2003

    I have cells showing text data like this:
    BD/JOHNSON&COELHA/CF#WQ8J5D
    CXLD/DUTHCER/523342

    I want to extract the varying length characters strings from left to right before the first forward slash only.

    Thanks for the help
    =LEFT(textstring,FIND("/",textstring,1)-1)

    should return everything to the left of the first "/".

  3. #3
    MrExcel MVP
    Join Date
    May 2002
    Posts
    14,220
    Post Thanks / Like
    Mentioned
    2 Post(s)
    Tagged
    1 Thread(s)

    Default Re: Extract text before first forward slash

    =left(a1,find("/",a1)-1)
    Two plus two equals five for large values of two.

  4. #4
    Board Regular
    Join Date
    Jan 2005
    Posts
    311
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default Re: Extract text before first forward slash

    Great! Forgot one other piece I must combine with vlookup:

    =VLOOKUP(J2,AGTNAME!$A$1:$E$3086,5,0)),"",VLOOKUP(J2,AGTNAME!$A$1:$E$3086,5,0))

    Again thank you

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •