+ Reply to Thread
Results 1 to 8 of 8

Text within a cell

  1. #1
    Forum Contributor
    Join Date
    07-18-2012
    Location
    New York
    MS-Off Ver
    2016
    Posts
    193

    Text within a cell

    Hello,

    I've seen different variations of this on the forum but when I try to use what has been suggested it won't work. I need a formula that will return the number 1 if a cell contains a specific text. The cells would contain:

    Smith, AB1
    or
    Doe, AB1

    I need it to look for "AB1"

    Thanks again for everyone's help.

  2. #2
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.92 (24120731))
    Posts
    9,108

    Re: Text within a cell

    try
    =IF(ISERROR(FIND("ab1",A1)),"",1)

    and copy down the rows
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  3. #3
    Forum Contributor
    Join Date
    07-18-2012
    Location
    New York
    MS-Off Ver
    2016
    Posts
    193

    Re: Text within a cell

    That's one of the variations that I tried already, I keep getting the message that says the formula contains an error and it highlights "AB1",A1.

  4. #4
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.92 (24120731))
    Posts
    9,108

    Re: Text within a cell

    can you upload/attach a sample spreadsheet here

    are you sure you are typing exactly as shown ?

  5. #5
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Text within a cell

    You can use etaf's formula but you need to replace function FIND with SEARCH. FIND does the same thing as SEARCH but FIND is case sensitive and search is not.

    =IF(ISERROR(SEARCH("ab1",A1)),"",1)
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

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

    Re: Text within a cell

    may be like it
    =IFERROR(FIND("AB1",A3)^0,"")
    copy down

  7. #7
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.92 (24120731))
    Posts
    9,108

    Re: Text within a cell

    thanks for the correction AlKey

  8. #8
    Forum Contributor
    Join Date
    07-18-2012
    Location
    New York
    MS-Off Ver
    2016
    Posts
    193

    Re: Text within a cell

    I just realized why it wasn't working, I had changed my deliminator to a pipe yesterday morning and forgot to change it back. I was still using a different formula than what you all posted so thank you for your help.

  9. #9
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Text within a cell

    Here's another one...

    =IF(COUNTIF(A1,"*AB1*"),1,"")

    Case is not a condition.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 7
    Last Post: 01-04-2014, 10:11 PM
  2. Formula to identify part of a text in cell from range of cells & insert adjacent cell text
    By Novicebutnotforlong in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 11-19-2013, 02:11 AM
  3. Search cell for multiple text , return comma separated text in separate cell if found
    By dangerdoug in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-01-2013, 01:52 PM
  4. Replies: 1
    Last Post: 01-25-2013, 12:44 AM
  5. Replies: 2
    Last Post: 11-29-2012, 11:27 AM

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