Update or CancelUpdate without AddNew or Edit

CPGDeveloper

Board Regular
Joined
Oct 8, 2008
Messages
190
Hi All~

I have a user that occasionally experiences this error -- "Update or CancelUpdate without AddNew or Edit"

The db I administer has about 20+ end users, split db, front end accde files on each users's desktop.

This error occurs (only occasionally) when he is creating a new entry into our db --

I have that process linked to a 'New' command button. Clicking the button opens a pop-up form, solicits some information from the user, and creates new entries into two tables using the information provided by the user.

My code uses two relatively simple 'INSERT' sql statements. It then determines the 'ID' of the newly created record and after refreshing the form's record source, I use .FindFirst to go to the newly created record.

After creating the record, and then going into another field in said record, does the user experience this error.

Any ideas? I could post the code if that's helpful -- nowhere in my project do I use .Update or .CancelUpdate, but perhaps there's something about editing a newly created record that I'm missing?
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
I take it that you are using a recordset. Without seeing the code I'd just be guessing. The initial thought is that code or user interaction is attempting to update a recordset but the .Update method hasn't been invoked when it should have been. No guarantees, but posting the code is a must do thing I'd say.
 
Upvote 0

Forum statistics

Threads
1,224,813
Messages
6,181,117
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top