+ Reply to Thread
Results 1 to 4 of 4

Search within text and IF solution needed

  1. #1
    Registered User
    Join Date
    03-29-2011
    Location
    arizona
    MS-Off Ver
    Excel 2007
    Posts
    2

    Search within text and IF solution needed

    Hello,

    First post here.

    I help and I'm hoping someone out there has an answer. Probably simple for a lot of you.

    I need to search within the text of a cell and output a certain value in the cell next to it.

    I'm currently using this: =IF(SEARCH("*1629*",A1,1),"1629","") but I need to serach for multiple values.

    I've attached an example. Row 1 has the result I need using the formula. Row 2 and 3 show the value I need and how it should look, but I just put the values there manually.

    A B
    cat dog xyz def ghi lakers suck "1629 1629
    apple tree house fly Lebron sucks too "1633" 1633
    it is hot in arizona "1655" really hot 1655


    thanks
    Attached Files Attached Files

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,420

    Re: Search within text and IF solution needed

    Do the numbers always have four digits and quotes around them?

    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    03-29-2011
    Location
    arizona
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Search within text and IF solution needed

    Yes it will. Thanks for any help. There may be other 4 digit numbers that I do not care about, these will not contain quotes.

    I figured the quotes were a way to distintuish the 4 digits I'm looking for, from other groups of 4 digits. If excel doesn't play like that, is there another way to distinguish my 4 digits from others?
    Last edited by sc1775; 03-30-2011 at 03:09 PM.

  4. #4
    Forum Expert
    Join Date
    12-23-2006
    Location
    germany
    MS-Off Ver
    XL2003 / 2007 / 2010
    Posts
    6,326

    Re: Search within text and IF solution needed

    Hi, try using following UDF

    Please Login or Register  to view this content.

+ 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