D
david epsom dot com dot au
I have code like this in the form before update event:
Private Sub Form_BeforeUpdate(Cancel As Integer)
Call WriteRecordToAuditTrail(Me.RecordsetClone, "DP", "qry_Rate", "Modify
Before")
End Sub
All the Audit function does is copy the data from the current record.
Sometimes I get a 'No Current Record' error.
If I break on error, I can see that the recordset clone does not have a
current record.
The subform is in datasheet view. There is no separate save button: this
subform automatically saves when the record looses focus.
The recordset is NOT empty, I was NOT at a new record, I just changed the
number in one field. Me.RecordsetClone is supposed to be initialised to the
current record, I have a current record which I have just edited. The error
is not 100% repeatable, sometimes it just goes away.
Any insight?
(david)
Private Sub Form_BeforeUpdate(Cancel As Integer)
Call WriteRecordToAuditTrail(Me.RecordsetClone, "DP", "qry_Rate", "Modify
Before")
End Sub
All the Audit function does is copy the data from the current record.
Sometimes I get a 'No Current Record' error.
If I break on error, I can see that the recordset clone does not have a
current record.
The subform is in datasheet view. There is no separate save button: this
subform automatically saves when the record looses focus.
The recordset is NOT empty, I was NOT at a new record, I just changed the
number in one field. Me.RecordsetClone is supposed to be initialised to the
current record, I have a current record which I have just edited. The error
is not 100% repeatable, sometimes it just goes away.
Any insight?
(david)