Conditional formatting - multiple criteria

Sah213

New Member
Joined
Feb 25, 2014
Messages
10
Hi there,

I was looking for some help. If anyone is willing to point my in the right direction, I'd be incredibly grateful. I'm currently trying to use conditional formatting to colour cells in column F, one of two different colours using the "Use a formula to determine which cells to format" option.


However I’m having trouble with the syntax of the argument because I’m not very good at IF, AND & OR statements.
The real life situation is that if an employee is receiving a nominal increase to their salary (noted in column D) & is based in london (noted in column C), a 5% increase can be applied (calculated in column F) before the cell becomes “red”, i.e. dictates to the end user that this is not within the acceptable boundaries.
However if the employee is NOT based in london, only a 3% increase can be applied before the cell becomes “red”.
If the % increase is “acceptable”, i.e. within the boundaries as per their location, then the cell in column F should be coloured green.

A simplified version is below;



If contents of cell D2 = “Promotion”, do nothing

BUT

(If contents of cell D2 = “Nominal Increase”,

AND

If contents of cell C2 = "London" AND number in cell F2 is ABOVE 5.01- colour cell F2 – red.
OR
If contents of cell C2 = "London" AND number in cell F2 is BELOW 5.01- colour cell F2 - green


ALSO


If contents of cell C2 <> "London" AND number in cell F2 is BELOW 3.01- colour cell F2 - green
OR

If contents of cell C2 <> "London" AND number in cell F2 is ABOVE 3.01- colour cell F2 - red




Table below in case that helps! Thank you!



NameCurrent Total CashLocationIncrease TypeIncreaseIncrease %New Total Cash FYI
Joe Bloggs£40,000London Promotion£3,0007.50£43,000
Fake Name £38,000Southampton Nominal Increase£2,0005.26£40,000
Tim Splash £21,000London Nominal Increase£2501.19£21,250
Robert Porridge£28,500London Nominal Increase£7002.46£29,200
James Kellogs£23,600Southampton Promotion£00.00£23,600
Lilly Allen £56,000Glasgow Nominal Increase£4000.71£56,400
Sophie Harper£78,000Edinburgh Promotion£7,0008.97£85,000
<colgroup><col width="110" style="width: 83pt;"> <col width="122" style="width: 92pt; mso-width-source: userset; mso-width-alt: 4461;"> <col width="110" style="width: 83pt;" span="3"> <col width="110" style="width: 83pt; mso-width-source: userset; mso-width-alt: 4022;"> <col width="126" style="width: 95pt; mso-width-source: userset; mso-width-alt: 4608;"> <tbody> </tbody>




 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
See if this works for you.
You will need to set up up 2 rules in conditional formatting. One for red & one for green.

Go to
-Conditional Formatting
-New Rule
-Use formula
Excel Workbook
ABCDEFG
1NameCurrent Total CashLocationIncrease TypeIncreaseIncrease %New Total Cash FYI
2Joe Bloggs40,000LondonPromotion3,0007.543,000
3Fake Name38,000SouthamptonNominal Increase2,0005.2640,000
4Tim Splash21,000LondonNominal Increase2501.1921,250
5Robert Porridge28,500LondonNominal Increase7002.4629,200
6James Kellogs23,600SouthamptonPromotion0023,600
7Lilly Allen56,000GlasgowNominal Increase4000.7156,400
8Sophie Harper78,000EdinburghPromotion7,0008.9785,000
Sheet
Cells with Conditional Formatting
CellConditionCell FormatStop If True
F21. / Formula is =IF(OR(AND(D2="Nominal Increase",C2="London",F2<5.01),AND(D2="Nominal Increase",C2<>"London",F2<3.01)),"TRUE")Abc
F22. / Formula is =IF(OR(AND(D2="Nominal Increase",C2="London",F2>5.01),AND(D2="Nominal Increase",C2<>"London",F2>3.01)),"TRUE",)Abc
 
Upvote 0

Forum statistics

Threads
1,220,965
Messages
6,157,120
Members
451,399
Latest member
alchavar

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