# How to compute if a date falls between two specified dates??

1. ## How to compute if a date falls between two specified dates??

Hi Everyone!

I have a worksheet which calculates productivity of resources. There is a cell in which user can input a date. Now I want to check whether the value user entered falls between a Start Date and End Date and if not then show an error message. Start Date and End Date are mentioned in two different cells in the same worksheet. Can anybody help me with a macro to achieve the same?

Below is a sample excel given.

 Start Date 3/12/12 End Date 05/06/13 Date Task Hours 03/12/12 Requirement Study 2 5/04/13 Plan Preparation 4 07/07/13 Review 5

Now you can clearly see the in the last row the date is beyond the End Date mentioned in the above table..so in this case user will be prevented to enter the value and shown an error message "Wrong Input".

2. ## Re: How to compute if a date falls between two specified dates??

that facility is in data validation

3. ## Re: How to compute if a date falls between two specified dates??

Thanks for replying! Can you please provide the specific steps or formula to achieve this?

4. ## Re: How to compute if a date falls between two specified dates??

Data tab/data validation /allow date/ between put in the absolute values of the cells with the 2 dates in eg \$b\$1 \$b\$2. you can choose an input message and a message when the wrong date is entered

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1