Another Conditional Formatting Formula needed?

D

Dan the Man

In Column A I have a list of last names (A4:A3500), and in Column P I have a
list of companies (P4:p3500). I'd like to use conditional formatting to
change the color of the last name in Column A (A4:A3500) to blue, when a
specific company name appears in Column P (P4:p3500). I'll assume that this
is an Array formula to use with conditional formatting, but couldn't get it.
I tried something like what you see below, but it didn't work:

=SUMPRODUCT(--($A$4:$A$3500=$A4),--($B$4:$B$3500=$B4))=Amethyst Counseling


Help on this one would be much appreciated?

Dan
 
D

Dave Peterson

Does this mean that the company name has to be on the same row as the last name?

If yes, you could:
select A4:a3500
Formula is: =p4="Amethyst Counseling"

If you mean that you want A4 to change colors if that company name appears in
any cell in P4:p3500, you could:

Select A4:A3500
formula is: =countif($p$4:$p$3500,"Amethyst Counseling")>0
 
D

Dan the Man

Hi Dave:

Yes I did mean that I want A4:A3500 to change colors if that company name
appears in any cell in P4:p3500. I tried your suggestion (repasted below),
but it changed all of the names in A4:A3500 to the same color/font,
regardless of the company name in P4:p3500. Any other suggestion would be
much appreciated.

Dan

Select A4:A3500
formula is: =countif($p$4:$p$3500,"Amethyst Counseling")>0
 
D

Dan the Man

I got it. I made a slight alteration to your formula:

=P4:p367="Amethyst Counseling"
 
D

daddylonglegs

Possibly that method works but it wouldn't be the correct way to do it, each
cell is really only evaluating the first cell in the range so just use

=P4="Amethyst Conseling"
 
D

Dave Peterson

Are you sure that works?

If yes, then good.

If no, you may want to restate your requirements.
 
D

Dan the Man

Works like a charm................I'm OCD about testing, and I checked
several cells!

Dan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top