Error Checking in Excel
Thanks Thanks:  0
Likes Likes:  0
Results 1 to 5 of 5

Thread: testing a value

  1. #1
    Board Regular
    Join Date
    Feb 2002
    Posts
    91
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    I have a value in cell A1 and i want to return the value true in C1 if A1 is equal to any value in the colum B. Columb B contains 150 cells of data.

  2. #2
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Austin, Texas USA
    Posts
    11,654
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    {=OR(A1=B1:B150)}

    Note: This is an array formula which must be entered using the Control+Shift+Enter key combination. The outermost braces, { }, are not entered by you -- they're supplied by Excel in recognition of a properly entered array formula.

    Or...

    =ISNUMBER(MATCH(A1,B:B,0))

    [ This Message was edited by: Mark W. on 2002-03-05 08:57 ]

  3. #3
    Board Regular Steve Hartman's Avatar
    Join Date
    Feb 2002
    Location
    Houston,Texas
    Posts
    417
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    =IF(ISNA(MATCH(A1,B:B,0)),"","True") in C1 will check all of column B in case the number of entries might change.

  4. #4
    MrExcel MVP Aladin Akyurek's Avatar
    Join Date
    Feb 2002
    Location
    The Hague, NL
    Posts
    83,645
    Post Thanks / Like
    Mentioned
    33 Post(s)
    Tagged
    6 Thread(s)

    Default

    On 2002-03-05 08:34, drag-driver wrote:
    I have a value in cell A1 and i want to return the value true in C1 if A1 is equal to any value in the colum B. Columb B contains 150 cells of data.
    In C1 enter: =ISNUMBER(MATCH(A1,B:B,0))

    If needed, B:B can be replaced by B1:B150.


  5. #5
    MrExcel MVP
    Join Date
    Feb 2002
    Location
    Austin, Texas USA
    Posts
    11,654
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    On 2002-03-05 08:59, Aladin Akyurek wrote:
    On 2002-03-05 08:34, drag-driver wrote:
    I have a value in cell A1 and i want to return the value true in C1 if A1 is equal to any value in the colum B. Columb B contains 150 cells of data.
    Been there... done that!

    In C1 enter: =ISNUMBER(MATCH(A1,B:B,0))

    If needed, B:B can be replaced by B1:B150.


Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

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