I have a form with a field called cbostartdate. When you advance to the next record 1 day is added to the current date by this code:
Dim NextDate As Date
NextDate = cboStartDate
DoCmd.GoToRecord , , acNext
If NewRecord Then
cboStartDate.Value = NextDate + 1
Is there a way to prevent the date advancing to a saturday or sunday? If I enter data on a monday and continue throug the week on Friday the next date appearing is of course Saturday. I would like it to skip the Saturday and Sunday and give the next Monday's date. I use a pop up calendar to choose the start date initially, but after that I want each new record to have a sequential date skipping the weekend. Any ideas?
Dim NextDate As Date
NextDate = cboStartDate
DoCmd.GoToRecord , , acNext
If NewRecord Then
cboStartDate.Value = NextDate + 1
Is there a way to prevent the date advancing to a saturday or sunday? If I enter data on a monday and continue throug the week on Friday the next date appearing is of course Saturday. I would like it to skip the Saturday and Sunday and give the next Monday's date. I use a pop up calendar to choose the start date initially, but after that I want each new record to have a sequential date skipping the weekend. Any ideas?