Dragging Down Conditional Formatting

tbones

New Member
Joined
Jul 18, 2008
Messages
43
Office Version
  1. 365
Platform
  1. Windows
hi I am having a problem with conditional formatting.
On the attached worksheet what I am looking for is to use a 3 way conditional colour format.
if cell A2 is less than B2 then I want the cell to go green
if cell A2 is more than B2 then I want the cell to go red
if cell A2 is = to B2 then I want the cell to go amber(yellow)

I can do this quite easily however when I want to drag the conditional format all the way down Column A it takes on the values that relate to the first cell conditional formatting so will not format to their equivalent cell. So using the 3 conditions I want
A3 to relate to B3
A4 to B4
A5 to B5
and so on.

I tried to use format painter but it still goes back to the values of row 2 and not its row that it is in.

Apologies if thats not clear.

Conditional Formatting
 

Excel Facts

Why does 9 mean SUM in SUBTOTAL?
It is because Sum is the 9th alphabetically in Average, Count, CountA, Max, Min, Product, StDev.S, StDev.P, Sum, VAR.S, VAR.P.
I suspect in the formula you used for the CF, you may have had an absolute cell reference (e.g. =$A$2>$B$2) so if you lose the $'s you end up with this (the format of which can be copied down to as many cells as you like)
conditional format.xlsx
AB
1Col ACol B
245
399
499
555
691
758
8109
9129
1023
1165
1299
1313
1499
1589
1689
1711
1859
19119
20129
21139
2239
23169
24129
2599
2699
2799
Sheet1
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A2:A27Expression=A2>B2textYES
A2:A27Expression=A2<B2textYES
A2:A27Expression=A2=B2textYES
 
Upvote 0

Forum statistics

Threads
1,215,068
Messages
6,122,950
Members
449,095
Latest member
nmaske

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