Conditional Formatting

mjmoon

Board Regular
Joined
Mar 1, 2005
Messages
249
I have a worksheet containing a list of departments (A1..A20), along with the number of OT hours (B1..B20) per month. In (C1..C20) I also have the department's percent of total OT hours calculated for that month.

What I would like to do is have the top five be conditional formatted to change their format to red so they stick out when the report is distributed, but I don't know how to do this. Any suggestions?

Thank you for your consideration.

Marc
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
In an adjacent column, use the rank() function to rank the depts. Then use the "formula is" option in conditional formatting for ranked value <=5
 
Upvote 0
Highlight the area you wish to format (in this case B1..B20), and under conditional formatting, select formula is and copy this in :-

Code:
=OR(A1=LARGE($B$1:$B$20,1),A1=LARGE($B$1:$B$20,2),A1=LARGE($B$1:$B$20,3),A1=LARGE($B$1:$B$20,4),A1=LARGE($B$1:$B$20,5))

This will give the 5 highest in that range.
 
Upvote 0

Forum statistics

Threads
1,215,323
Messages
6,124,244
Members
449,149
Latest member
mwdbActuary

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