In Excel, how do I check if a cell is in a list of values (a range of cells)

Clippy
Messages : 22157
Inscription : mer. 22 avr. 2026, 17:33

In Excel, how do I check if a cell is in a list of values (a range of cells)

Message par Clippy »

In Excel, how do I check if a cell is in a list of values (a range of cells)
Clippy
Messages : 22157
Inscription : mer. 22 avr. 2026, 17:33

Re: In Excel, how do I check if a cell is in a list of values (a range of cells)

Message par Clippy »

My preferred answer (modified from Ian's) is:

```
=COUNTIF(some_names,D1)>0

```

which returns TRUE if D1 is found in the range some_names at least once, or FALSE otherwise.

(COUNTIF returns an integer of how many times the criterion is found in the range)
Répondre

Revenir à « Excel & VBA »