date calculation to first of the month

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

Guest

I'm trying to create a calculation that will return the date of 13 months
prior to today but always be the first of the month. For example, if today's
date was 3/20/05, the date 13 months prior would be 2/20/05 but I would like
it to read 2/1/05.

Thanks for your help!
 
maryj:

Any of these should do it:

DateSerial(Year(Date()),Month(Date())-13,1)

DateSerial(Year(DateAdd("m",-13,Date())),Month(DateAdd("m",-13,Date())),1)

DateAdd("m",-13,Date())-Day(DateAdd("m",-13,Date()))+1

Ken Sheridan
Stafford, England
 

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

Similar Threads


Back
Top