Conditional Formatting - Before and after expiry date

Cassidy, Niamh 0 Reputation points
2023-01-25T14:50:25.7266667+00:00

I'm trying to set up conditional formatting for a spreadsheet. I have a date when I received a consent letter, I'd like this to be coloured green if consent is still valid and red if consent has expired (18 months after receipt of letter).

Any suggestions appreciated, TIA!

Microsoft 365 and Office | Excel | For business | Windows
{count} votes

1 answer

Sort by: Most helpful
  1. Dillon Silzer 60,701 Reputation points Volunteer Moderator
    2023-01-25T17:35:39.3833333+00:00

    Hello,

    So to start off, 18 months ago was Sunday July 25, 2021.

    I have two columns (Name, Received).

    User's image

    Highlight your column you want conditional formatting on > go to Conditional Formatting > New Rule.

    User's image

    Now go to Use a formula to determine which cells to format > Enter your column (in my case it is B1) as =B1<TODAY()-547.506

    User's image

    The 547.506 is an approximation for 18 months ago. Press OK and it should highlight like my example above.

    Do the same for adding the rule for 18 months ago or greater:

    User's image

    You will then get as a final result:

    User's image


    If this is helpful please accept answer.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.