Validate a cell - Workdays only

R

Rory

Hopefully this should be fairly easy - I have a cell on a
worksheet that a user enters a date into, but I need to
set it so only a workday can be entered.
 
C

Chip Pearson

Rory,

Select the cell in question and go to the Data menu and choose
Validation. There, select 'Custom' from the Allow list, and enter
the following formula:

=NOT(OR(WEEKDAY(A1)=1,WEEKDAY(A1)=7))

Change the A1 reference to the cell in question.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com
 
J

Jason Morin

Go into Data > Validation. Under Allow: Custom. Now
insert:

=AND(TEXT(A1,"ddd")<>"Sun",TEXT(A1,"ddd")<>"Sat")

HTH
Jason
Atlanta, GA
 
R

Rory

Thanks
-----Original Message-----
Rory,

Select the cell in question and go to the Data menu and choose
Validation. There, select 'Custom' from the Allow list, and enter
the following formula:

=NOT(OR(WEEKDAY(A1)=1,WEEKDAY(A1)=7))

Change the A1 reference to the cell in question.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com





.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top