(Msg. 1) Posted: Tue Nov 18, 2008 11:09 am
Post subject: Validate cell for date, as well as day of the week Archived from groups: microsoft>public>excel (more info?)
I have looked through what is out there and I am not hopeful that this can be
done, but here goes...
I have a cell that will be populated with a date. I need to make sure that
the date does not fall on a Saturday or a Sunday and that the date is not
older than 2 days. I was hoping to be able to do both of these in a single
validation, but I have a snag. The weekday function requires a cell, but I
am validating on the current cell and, even though I do know what it is, i
want to allow that that may change. How can I accomplish this?
(Msg. 2) Posted: Tue Nov 18, 2008 6:45 pm
Post subject: RE: Validate cell for date, as well as day of the week [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
David
I could not get data validation to work. But until someone answers your
query perhaps you can use conditional formatting.
Set the cell condition to; Formula Is and paste the formula
You can set this over a range - just type the reference to the first cell in
the range. The conditional formatting can be copied anywhere using the Paste
Format icon.
Peter Atherton
"David Langschied" wrote:
> I have looked through what is out there and I am not hopeful that this can be
> done, but here goes...
>
> I have a cell that will be populated with a date. I need to make sure that
> the date does not fall on a Saturday or a Sunday and that the date is not
> older than 2 days. I was hoping to be able to do both of these in a single
> validation, but I have a snag. The weekday function requires a cell, but I
> am validating on the current cell and, even though I do know what it is, i
> want to allow that that may change. How can I accomplish this?
>
>
>
(Msg. 3) Posted: Tue Nov 18, 2008 7:02 pm
Post subject: RE: Validate cell for date, as well as day of the week [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
Use a formula (custom) in data validation and insert the following formula:
Replace A1 with the first cell in the selected cells to apply the validation
to.
or you could weekday function in lieu of text function but I like the above
because it is self documenting as to which days to exclude.
--
Regards,
OssieMac
"David Langschied" wrote:
> I have looked through what is out there and I am not hopeful that this can be
> done, but here goes...
>
> I have a cell that will be populated with a date. I need to make sure that
> the date does not fall on a Saturday or a Sunday and that the date is not
> older than 2 days. I was hoping to be able to do both of these in a single
> validation, but I have a snag. The weekday function requires a cell, but I
> am validating on the current cell and, even though I do know what it is, i
> want to allow that that may change. How can I accomplish this?
>
>
>
(Msg. 4) Posted: Tue Nov 18, 2008 11:33 pm
Post subject: RE: Validate cell for date, as well as day of the week [Login to view extended thread Info.] Archived from groups: per prev. post (more info?)
Hi,
In the data validation Custom area enter the formula
=AND(MOD(A1,7)>1,(TODAY()-A1)<2)
Note you specified a date not more than two days old, but you did not
indicate if that date could be in the future.
If this helps, please click the Yes button
Cheers,
Shane Devenshire
"David Langschied" wrote:
> I have looked through what is out there and I am not hopeful that this can be
> done, but here goes...
>
> I have a cell that will be populated with a date. I need to make sure that
> the date does not fall on a Saturday or a Sunday and that the date is not
> older than 2 days. I was hoping to be able to do both of these in a single
> validation, but I have a snag. The weekday function requires a cell, but I
> am validating on the current cell and, even though I do know what it is, i
> want to allow that that may change. How can I accomplish this?
>
>
>
All times are: Eastern Time (US & Canada) (change)
Page 1 of 1
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum