Excel formulas

Copper Contributor

I am trying to find the right formula for this:

 

If a certain text is within a range of cells, then it returns a value, if not it returns another value.

 

It is close to the IF function, but not exactly because instead of the logical test being = to one specific cell, i want it to search within a range of cells.

1 Reply

@laurenhall7589 

As variant

=IF( COUNTIF(<range>,<text>), Value1, Value2)