Automatic change color of searched value in a column...

M

MS Excel

Per below list, i want to change colour of a cell whose value matches with
CELL A1 contents. For example:

A1 = 239.05
Column B
1) 235.66
2) 154.60
3) 239.05
4) 522.05

As I enter 239.05 in cell A1 it automatically change colour of CELL B3
(that's equal to 239.05). Any possibility?
Be noted that it should seach for the first occurence only.. also what
amendment can enable the proposed solution to search for all first & next
occurence ?


Regards,
Syed
 
D

Dave Peterson

You can use Format|Conditional formatting.

Select column B and with B1 active:
format|Conditional formatting
Cell value is:
(type) =$a$1

Format the way you want.
 
R

Ragdyer

To highlight *only* the first occurrence of the cell that matches the data
in A1,
Select Column B, from B1 to whatever, with the focus of the selection in B1
(colored white), then:
<Format> <Conditional Format>,
Change "Cell Value Is" to "Formula Is",
And enter this in the next box:

=AND(COUNTIF($B$1:B1,$A$1)=1,$A$1=B1)

Click on "Format" and choose whatever format you wish,
Then <OK> <OK>

To highlight only the first *2 matches*, enter this formula:

=AND(OR(COUNTIF($B$1:B1,$A$1)=1,COUNTIF($B$1:B1,$A$1)=2),$A$1=B1)
 
M

MS Excel

THANKS FOR YOUR HELP..

One more thing, how to automatically change color of item which have same
value in different column... like in below data data in B1 is equal to C3
and B4 is equal to C1.
Simply the proposed solution should match a column with another column and
change color of matched cells.

Column COLUMN
B C
1) 235.66 552.05
2) 154.60 623.00
3) 239.05 235.66
4) 522.05 154.60

Hope I am clear..
 
B

Bob Phillips

That is a conditional function formula, so it will highlight all matching
items. You asked to colour cell, not select.
 

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