Thanks Joe.
Steve, only slightly familiar with VBA. Would this line of code need exact year and date entered? DateToCheck = DateSerial(Year(Date), Month(Date), 1)
Thanks Joe.
Steve, only slightly familiar with VBA. Would this line of code need exact year and date entered? DateToCheck = DateSerial(Year(Date), Month(Date), 1)
It is all taken care of in the code.
The date function, Date(), returns the current date.
The date serial function, DateSerial(Year(Date), Month(Date), 1), calculates the first of the month. (look up dateSerial in Help)
Every time the dB is opened, the code runs. If there is not an entry for the current month, the append query is executed; if there IS an entry in the table for the current month, the code falls through without running the append query. So the append query executes only once per month, no matter how many times the dB is opened in a month.