Checking Dates in Ranges of Dates

Stravitch

New Member
Joined
Apr 13, 2016
Messages
6
I've been trying to figure out if it is possible, which I'm sure it is, if I can check a date against mulitple ranges of dates to see if it falls between any of them.

What I'm ultimately trying to do is have a list of reserved spans of dates then on another worksheet have a dynamic calendar that will highlight those days as reserved. It's very similar to the template for the Student Assignment Planner in the online template list but instead of single dates that match to a date on the calendar, there would be ranges that are reserved.

If I've done a poor job of explaining, please let me know. Thank you for any input you can point me in the direction of!
 

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
check a date against mulitple ranges of dates to see if it falls between any of them.

Hi, welcome to the forum!

You could try something like this:


Excel 2013
ABCDE
1Reserved Dates
2FromToDate to test
301/04/201610/04/201602/04/2016Reserved
415/04/201620/04/201612/04/2016Not Reserved
515/04/2016Reserved
Sheet1
Cell Formulas
RangeFormula
E3=IF(COUNTIFS(A:A,"<="&D3,B:B,">="&D3),"Reserved","Not Reserved")
 
Upvote 0
Amazing! Thank you so much, I was SO close.

As an aside, why do you need the quotes around the operators >= and <=?
 
Upvote 0

Forum statistics

Threads
1,216,589
Messages
6,131,596
Members
449,657
Latest member
Timber5

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