Results 1 to 3 of 3

IF test; formula for testing whether a cell is equal any out of a list of cells.

Threaded View

  1. #1
    Registered User
    Join Date
    04-21-2010
    Location
    Oslo, Norway
    MS-Off Ver
    Excel 2007
    Posts
    2

    IF test; formula for testing whether a cell is equal any out of a list of cells.

    I'm trying to check whether cell A73 is equal to any of the cells A2 to A27. (Excel 2007)

    The values in the cells are strings, i.e words.

    First attempt was =IF(A73=A2:A27;1;0), this gives me #VALUE! error.

    I have started on a formula that is working, but it's rather tedious. This formula seems to be working for checking A73 against A27 to A20, and I'd have to extend it with 18 more IF statements to complete it.
    =IF(A73=A27;1;IF(A73=A26;1;IF(A73=A25;1;IF(A73=A24;1;IF(A73=A23;1;IF(A73=A22;1;IF(A73=A21;1;IF(A73=A20;1;0))))))))

    There's got to be a simpler way of doing this with a very short formula.

    Any help is appreciated.
    Last edited by Aco; 04-21-2010 at 07:25 AM.

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