testing a value

drag-driver

Board Regular
Joined
Feb 18, 2002
Messages
91
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.
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.
{=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
 
Upvote 0
=IF(ISNA(MATCH(A1,B:B,0)),"","True") in C1 will check all of column B in case the number of entries might change.
 
Upvote 0
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.
 
Upvote 0
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! :smile:

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

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

Forum statistics

Threads
1,223,375
Messages
6,171,735
Members
452,419
Latest member
mapa

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top