Results 1 to 2 of 2
  1. #1
    2 Star Lounger
    Join Date
    Sep 2001
    Location
    Blue Springs, Missouri, USA
    Posts
    108
    Thanks
    1
    Thanked 0 Times in 0 Posts

    SEARCH function (XL2k SR1)

    Can I use the SEARCH function to find multiple values? That is... I want to search for either of 2 text strings within a text field. I have a list of people that may have a suffix of either DPM or Dr.

    Thanx

    Dennis

    <img src=/S/gramps.gif border=0 alt=gramps width=20 height=20>

  2. #2
    WS Lounge VIP sdckapr's Avatar
    Join Date
    Jul 2002
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    11,225
    Thanks
    14
    Thanked 342 Times in 335 Posts

    Re: SEARCH function (XL2k SR1)

    If you want either of them in you could use:
    <pre>=OR(NOT(ISERROR(SEARCH("String1",A1))),NOT(IS ERROR(SEARCH("String2",A1))))</pre>


    To search for "string1" and "string2" in cell A1

    If you wanted both to be in, use:
    <pre>=AND(NOT(ISERROR(SEARCH("String1",A1))),NOT(I SERROR(SEARCH("String2",A1))))</pre>


    Steve

Posting Permissions

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