Using Conditional Formatting with expired dates

Mustafa Evans

New Member
Joined
Mar 18, 2010
Messages
35
Office Version
  1. 2010
Platform
  1. Windows
Hi all, hope you can help am attempting to use conditional formatting to show expired and near expired (5 days) dates in my spreadsheet.

For expired dated i would like those cells to be RED.
For dates about to expire in the next 5 days those cells should be AMBER
and finally, those cells that are not about to expire should remain WHITE.

Am trying to use the TODAY() function in my calculations. Hope you can help.

The dates are in columns H, I and J, but begin in cell H8.

RED - =H8<=TODAY()
AMBER - =H8>=TODAY()-5
WHITE - =H8>TODAY()

Having done this am unsure what order they should run. Or is there a easier way.

Many thanks.
 

Mustafa Evans

New Member
Joined
Mar 18, 2010
Messages
35
Office Version
  1. 2010
Platform
  1. Windows
That's the thing, both, but i realise now that this can't happen. If G is Urgent I&J cell should be grey, but i need a way of showing dates that have expired aswell.
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.

Fluff

MrExcel MVP, Moderator
Joined
Jun 12, 2014
Messages
56,832
Office Version
  1. 365
Platform
  1. Windows
You have a choice, grey cells or red/amber cells, unless you change one of them to font colour & one to be fill colour.
 

Mustafa Evans

New Member
Joined
Mar 18, 2010
Messages
35
Office Version
  1. 2010
Platform
  1. Windows
You have a choice, grey cells or red/amber cells, unless you change one of them to font colour & one to be fill colour.
I really don't mind. OK Can we keep cell GREY, and do something to show dates expiries. Genuinely grateful for your assistance.
 

Fluff

MrExcel MVP, Moderator
Joined
Jun 12, 2014
Messages
56,832
Office Version
  1. 365
Platform
  1. Windows
How about
+Fluff v2.xlsm
FGHIJ
8
9Urgent15/10/202001/11/2020
10
11Routine15/10/202001/11/2020
12
13
14
Main
Cells with Conditional Formatting
CellConditionCell FormatStop If True
I8:J500Expression=$G8="Urgent"textNO
H8:H500Expression=$G8="Routine"textNO
H8:J500Expression=AND(H8<>"",H8<TODAY())textNO
H8:J500Expression=AND(H8<>"",H8<=TODAY()+5)textNO
 
Solution

Mustafa Evans

New Member
Joined
Mar 18, 2010
Messages
35
Office Version
  1. 2010
Platform
  1. Windows
Send me you address for the biggest choc box ! :) It all works, Thanks so very much.
 

Fluff

MrExcel MVP, Moderator
Joined
Jun 12, 2014
Messages
56,832
Office Version
  1. 365
Platform
  1. Windows
You're welcome & thanks for the feedback.
 

Watch MrExcel Video

Forum statistics

Threads
1,130,092
Messages
5,640,066
Members
417,125
Latest member
sfreind

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
Top