Conditional Formatting Using Cell References

Orion19

Board Regular
Joined
Dec 18, 2017
Messages
56
Hello! I'm using Excel for Mac 2017 Version 15.41. I'm running into an issue I don't understand using conditional formatting.

I'm attempting to highlight a row one of three different colors depending on a specific condition. I have an upper limit, lower limit, and an age. If the age is below the lower limit nothing happens. If the age falls between the limits I want the row to turn yellow. If the age is above the upper limit the row turns green. For the yellow condition, this formula does exactly what I want it to do (the age = 2 and is $C$1 in all these examples):

=AND($C$1>=0, $C$1<=3)

However, I'd like to reference a cell instead of having a specific numerical value to the right of the equal sign in each argument. I entered the following formula but only one cell in the highlighted range turns yellow:

=AND($C$1>=B5, $C$1<=C5)

What do I need to change to have the entire selected range change color? When I get it right I want to be sure C1 is locked when I copy the formula (hence $C$1) but I'm not sure how to format the $ in the other cell references. Thank you in advance for your help and please let me know if more information is required!

<style></style>
 

Excel Facts

Back into an answer in Excel
Use Data, What-If Analysis, Goal Seek to find the correct input cell value to reach a desired result
if i'm understanding you correctly than maybe...

=AND($C$1>=$B5, $C$1<=$C5)
 
Upvote 0
if i'm understanding you correctly than maybe...

=AND($C$1>=$B5, $C$1<=$C5)

I gave that a shot and all cells turned white. It makes sense to lock the column, but I have no idea why I'm not getting that result. <style></style>
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,180
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