Validation part of a date in a table

G

GeorgieGirl

Is there anyway that I can validate that the day part of an expression is the
last day of that month? The user can choose any month and year, but I want
the day to always be the last day of that month. Any help is appreciated.
 
F

fredg

Is there anyway that I can validate that the day part of an expression is the
last day of that month? The user can choose any month and year, but I want
the day to always be the last day of that month. Any help is appreciated.

To determine the last day of any month:

=DateSerial([What Year],[What Month]+1,0)

i.e. DateSerial(2006,7+1,0) = 7/31/2006
 
G

GeorgieGirl

Thanks for the quick reply, I will try this.

fredg said:
Is there anyway that I can validate that the day part of an expression is the
last day of that month? The user can choose any month and year, but I want
the day to always be the last day of that month. Any help is appreciated.

To determine the last day of any month:

=DateSerial([What Year],[What Month]+1,0)

i.e. DateSerial(2006,7+1,0) = 7/31/2006
 

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