Using date validation with default text

bobsie

New Member
Joined
Oct 13, 2011
Messages
6
Hi all. I want to ensure users are putting valid dates into a column, say A2:A100.
I would like a default text entry of 'Not Known' to be valid as well in A2:A100.

Date and text validation is not that straightforward, can anyone help? Thanks.
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.
You didn't tell us which dates are valid, but here's an example you can adapt to your dates. In this example I want to limit dates to the current year (2018).

1. Select A2:A100
2. Data>Validation>Custom
3. Enter this formula in the dialog box:
Code:
=OR(A2="Not Known",AND(A2>=DATE(2018,1,1),A2<=DATE(2018,12,31)))
 
Upvote 0
You didn't tell us which dates are valid, but here's an example you can adapt to your dates. In this example I want to limit dates to the current year (2018).

1. Select A2:A100
2. Data>Validation>Custom
3. Enter this formula in the dialog box:
Code:
=OR(A2="Not Known",AND(A2>=DATE(2018,1,1),A2<=DATE(2018,12,31)))

That is a huge help, much appreciated!
 
Upvote 0

Forum statistics

Threads
1,224,825
Messages
6,181,189
Members
453,020
Latest member
Mohamed Magdi Tawfiq Emam

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