Acess, How do I make a date"The first Day of this month" and Last

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to set the default date value in an Unbound box, "The First
MM/DD/YYYY of This Month" and in another Unbound box, "The Last MM/DD/YY of
This Month" (What ever the month happens to be). Any suggestions? Please Help.
 
Randy said:
I am trying to set the default date value in an Unbound box, "The First
MM/DD/YYYY of This Month" and in another Unbound box, "The Last MM/DD/YY of
This Month" (What ever the month happens to be). Any suggestions? Please Help.

FirstOfThisMonth: DateSerial(Year(Date()), Month(Date()), 1)

LastOfThisMonth: DateSerial(Year(Date()), Month(Date()) + 1, 0)
 
I am trying to set the default date value in an Unbound box, "The First
MM/DD/YYYY of This Month" and in another Unbound box, "The Last MM/DD/YY of
This Month" (What ever the month happens to be). Any suggestions? Please Help.

DateSerial(Year(Date()), Month(Date()), 1) is the first day of the
month; DateSerial(Year(Date()), Month(Date()) + 1, 0) is the last.

John W. Vinson[MVP]
Join the online Access Chats
Tuesday 11am EDT - Thursday 3:30pm EDT
http://community.compuserve.com/msdevapps
 

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

Back
Top