Conditional Formatting for 2,3,4,5 of the same numbers.

serge

Well-known Member
Joined
Oct 8, 2008
Messages
1,404
Office Version
  1. 2007
Platform
  1. Windows
Hi everyone,

I need help with a CF that would format when 2 numbers are the same or 3 the same or 4 or5.

A1:E1

43,43,48,52,55. the 2, 43 would be highlighted with 1 color.
or
43,43,43,52,55. the 3, 43 would be highlighted a different color, etc...

and if I have :

43,43,43,55,55. the 3, 43 and 2, 55 would be highlighted a different color each.

I hope it's clear enough ?

Thank you for help... Serge.
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
Select the range A1:E1 and use this formula in conditional formatting

=COUNTIF($A1:$E1,A1)=2

format as required and repeat for 3, 4 and 5

(I assume you have Excel 2007 or later otherwise you are limited to 3 formats.....)
 
Upvote 0
Hi Barry,

Thank you very much, that's exactly what I needed.

Regards... Serge.
 
Upvote 0
Barry, Great solution..

On a related note..
I've noticed (in xl2007) if you were to now Click on any cell A1:E1 (after applying the c/f) and you use the Format Painter to c/f the Range(B1:E4) - When you then click on say Cell C3, and then C/f Manage Rules - both the formula box and the Applys to box
show "strange" cell references. Am I seeing correctly?

Jim
 
Upvote 0

Forum statistics

Threads
1,214,936
Messages
6,122,340
Members
449,079
Latest member
rocketslinger

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
Back
Top