Conditional formatting

jarhead58

Active Member
Joined
Sep 21, 2017
Messages
367
Office Version
  1. 2021
Platform
  1. Windows
I thought this was pretty straight forward but I guess not. I have a cell that I want to alternate colors between green and red depending on another cell being > or < a third cell. For example I want A7 green if B8>=A8 and red if B8<A8. I've tried the Formula Rule Type with A7 highlighted, $B$8>=$A$8 then format fill green and a second rule with $B$8<$A$8 then format fill green but it doesn't work. It always stays green in each criteria.
 

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
temp macro work2.xlsm
AB
7
8109
Sheet5
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A7Expression=$B$8<$A$8textNO
A7Expression=$B$8>=$A$8textNO
 
Upvote 0
There is a seemingly extra = at the beginning of the equation, but it is necessary.
 
Upvote 0
Solution
Glad to help. I've gotten stumped by this exact thing before. And, yes, it is South Carolina.
 
Upvote 0

Forum statistics

Threads
1,223,952
Messages
6,175,594
Members
452,655
Latest member
goranzoric

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