RE: How do I avoid 80040E21 error from AddNew after failed Update?

Tech-Archive recommends: Fix windows errors by optimizing your registry





"wrighj" wrote:

I am using the ADO 2.5 library, Access 2003 and VBA. After receiving and
handling a 80040E21 (dup key) error from an Update method, I receive this
same error from the AnnNew (no fields/data parameters provided) method.

I just answered my own question. By performing a CancelUpdate in the err
handling, the Recrodset is reset allowing the sebsequent methods (e.g.,
AddNew) to execute without error.
.