Conditional format formula needed

RickeyS

Board Regular
Joined
Jun 23, 2006
Messages
222
I need to have a cell E16 turn color (green) if the text typed in it matches text in any cell from C16:I17.
How would I write this formula?
Thanks
Rick
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
50,577
Office Version
  1. 365
Platform
  1. Windows
Try
=COUNTIF(C16:I17,E16)>1
 

Richard Schollar

MrExcel MVP
Joined
Apr 19, 2005
Messages
23,707
Rick

Maybe you want to expand on what you wrote because, as written, pgc's formula does exactly what you ask, but isn't very useful, whereas Peter's technically only matches certain conditions, but I suspect is actually what you meant.

Richard
 

RickeyS

Board Regular
Joined
Jun 23, 2006
Messages
222
Richard, you are correct Peter's works the way I need it to, (Thanks Peter) PCG's seems to always make the cell change color no mater what text is in it.
Thanks again,
Rick
 

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
50,577
Office Version
  1. 365
Platform
  1. Windows
PCG's seems to always make the cell change color no mater what text is in it.
That is because E16 is in the range C16:I17 and E16 will always match itself.
 

Forum statistics

Threads
1,141,219
Messages
5,705,086
Members
421,378
Latest member
CarlosDuran

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
Top