I put a simple command in the AfterUpdate event property of a form, to update a "modified date" field:
Private Sub Form_AfterUpdate(Cancel As Integer)
Me![txtModDate] = Date
End Sub
Then when I try to add or edit a record and go to the next one, I get the message
"You can't go to the specified record--you may be at the end of a recordset."
And I can't save the record at all.
When I take that same code and put it in the BeforeUpdate event property of the form, it works fine.
What's so different about those two that they behave so differently?
Thanks in advance to anyone who has insight into this problem.
Dan Lee
Private Sub Form_AfterUpdate(Cancel As Integer)
Me![txtModDate] = Date
End Sub
Then when I try to add or edit a record and go to the next one, I get the message
"You can't go to the specified record--you may be at the end of a recordset."
And I can't save the record at all.
When I take that same code and put it in the BeforeUpdate event property of the form, it works fine.
What's so different about those two that they behave so differently?
Thanks in advance to anyone who has insight into this problem.
Dan Lee