Access Form Control Source coding for Date field
Posted on 2015-01-19
I have a daily down load of data that I do year around. This data does not need to include multiple years. So, every January this data search includes records from the previous year, which I do not need to carry over. I'd like it to only download the current year. However, the problem is that the source website will only allow me to download 1000 records maximum. Currently, there are about 500 records permonth so I just can't leave the control source set to 1-1-Current year.
Currenlty I am using
=DateSerial(Year(Date()),Month(Date()),Day(Date()))-90 (This is always 90 days less than "today's date")
However, I would like to change this.
I need the date to be January 1, Current Year. (1-1-2015) until 90 days of the current year have expired. Then I need it to be 90 days less than the current date. So every year it changes automatically with the calendar and will not include records from the previous year.