Conditional Formatting to change colour of one cell in a range depending on sum of range

rugby_nut

New Member
Joined
Jan 13, 2009
Messages
42
Hi everyone,

I've not used the forum for some time now but I'm stuck with this Conditional Formatting (CF) problem. Hoping you guys can help.

I have a range in a row for AM, PM and NTS shifts across the days of the week, the user inputs the relevant shift score into each day. Depending on whether the shift target is met (qty in another cell), I have added CF to the range, so each cell will turn red if target not met and green if it is. So 400 for this example.
My problem is that when the overall schedule target (2200 in this example) is met, the quantity for that shift is very often short of the shift target, so the cell turns red. But I want to show this instance by highlighting the cell blue, to indicate the overall target has been met and there's no red cell. So where the last NTS shift has 225, this is short of the shift target so turns red, but I want this cell to turn blue as the overall schedule of 2200 has been achieved. The overall schedule is not always made to the exact quantity, it can go over slightly.

Please let me know if more information is required. Thanks.

ScheduleCompletedBalanceShift TargetAMPMNTSAMPMNTS
220030000400410405350405405232
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
is this what you mean

3 rules , 1 for RED / Green and Blue
SO if the shift sum as entered from left to right is equal to the shedule 2200 , then it turns Blue, with RED Text to show its under the target itself , but the total shifts met the overall

Book15
ABCDEFGHIJ
1ScheduleCompletedBalanceShift TargetAMPMNTSAMPMNTS
2220030000400410405350405405232
Sheet1
Cells with Conditional Formatting
CellConditionCell FormatStop If True
E2:J2Expression=SUM($E2:E2)>=$A$2textNO
E2:J2Expression=E2>=$D2textNO
A2Expression=SUM($E$2:$J$2)<A2textNO
E2:J2Expression=E2<$D2textNO
 
Upvote 0
Solution

Forum statistics

Threads
1,214,915
Messages
6,122,217
Members
449,074
Latest member
cancansova

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