Conditional formatting based on another value

keymoo

New Member
Joined
May 31, 2012
Messages
19
I have two number columns A and B.

I want to highlight column A with either a GREEN fill or RED fill.

If the value of A is greater than B*0.95 AND A is less than B*1.1 fill it GREEN.
If the value of A is greater than or equal to B*1.1 OR A is less than or equal to B*0.95 fill it RED.

Been struggling to get this working, thanks for looking.

I'm using Office 365 latest version.
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Assuming your data starts in A2, select A2:a & last row and use this formula for green
=AND(A2>B2*0.95, A2<B2*1.1)
and this for red
=AND(A2<>"",OR(A2<=B2*0.95, A2>=B2*1.1))
 
Upvote 0

Forum statistics

Threads
1,224,818
Messages
6,181,151
Members
453,021
Latest member
Justyna P

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