+ Reply to Thread
Results 1 to 4 of 4

Extract text left and right of character

  1. #1
    Registered User
    Join Date
    08-13-2012
    Location
    durham
    MS-Off Ver
    Excel 2003
    Posts
    13

    Extract text left and right of character

    We have cells with for example the following info...

    A-10A SUPER DETAIL SETS - 1:48 Scale - 26001
    '69 Camaro Z\28 2 in 1 - 1/25 - 85-2148

    What were trying to do is to clean up the data and gain the scale info from each cell so for example

    A-10A SUPER DETAIL SETS - 1:48 Scale - 26001 we would have a result of 1:48
    '69 Camaro Z\28 2 in 1 - 1/25 - 85-2148 we would have a result of 1/25

    The scale info could reside anywhere in the cell no set position and not always with the text scale in it the common elements I suppose will always be a 1: or a 1/ then obtaining the following set of no's till you hit a space would return the scale value.

  2. #2
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,147

    Re: Extract text left and right of character

    hi stuartm4h, is it possible that it doesnt have any? if not, then:
    =LEFT(REPLACE(A1,1,FIND(IF(ISERR(FIND(":",A1)),"/",":"),A1)-2,""),FIND(" ",REPLACE(A1,1,FIND(IF(ISERR(FIND(":",A1)),"/",":"),A1)-2,""))-1)

    if it has, maybe:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Thanks, if you have clicked on the * and added our rep.

    If you're satisfied with the answer, click Thread Tools above your first post, select "Mark your thread as Solved".

    "Contentment is not the fulfillment of what you want, but the realization of what you already have."


    Tips & Tutorials I Compiled | How to Get Quick & Good Answers

  3. #3
    Forum Expert tigeravatar's Avatar
    Join Date
    03-25-2011
    Location
    Colorado, USA
    MS-Off Ver
    Excel 2003 - 2013
    Posts
    5,361

    Re: Extract text left and right of character

    stuartm4h,

    Welcome to the forum!
    Here's an alternate formula:
    Please Login or Register  to view this content.
    [EDIT]
    Managed to get it a bit shorter:
    Please Login or Register  to view this content.
    Last edited by tigeravatar; 05-20-2013 at 12:20 PM.
    Hope that helps,
    ~tigeravatar

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  4. #4
    Registered User
    Join Date
    08-13-2012
    Location
    durham
    MS-Off Ver
    Excel 2003
    Posts
    13

    Re: Extract text left and right of character

    Works a treat many thanks was side tracked with a little project then back to this one by the looks of things is going to be all about picking out keywords from strings so I can build up a defined breakdown of the info by key elements.

+ 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