error 2046

  • Thread starter Thread starter Dick Minter
  • Start date Start date
D

Dick Minter

docmd.runcomand acCmdSaveRecord and acCmdDeleteRecord are producing error
code 2046 and I cannot determine why. I have tried saving the record with:

If me.dirty then
me.dirty = false
end if

But, the delete command still gets the error. What is producing the error?

DM
 
Quite possibly the form's popup property is set to true which blocks certain
instances of saving or deleting.
 
The form is not a popup. Further info:

My form's source is a table that temporaraly holds a single record. When
"posted" a "voucher" report is printed, the data is distriubted to permanent
tables,
and the current record is deleted, or at least that is the intent.

I've tried several ways to effect the delete including the docmd.runcomand,
an sql delete query, and most recently a recordset delete. The record
deletes from the table OK, but the data must still be in a buffer because the
form still sees it. If I place a "me.refresh" after the recordset delete,
the form shows an error notation in the linked data fields, but the form will
actually permit a edit menu delete action as though the record still exists.
How can I cause the delete buffer to empty? I tried calling the form's
afterdeleteupdate event, but Access says the procedure "is not defined." (My
syntax may be wrong here, but I copied and pasted it in the code to be sure
it was correct.)

DM
 
Back
Top