Programme works most of time - deleted records

scoop10000

New member
Local time
Today, 02:56
Joined
Aug 19, 2004
Messages
9
I have an annoying problem with my programme that trips over once or twice a week.

I have a form (customer) and subform (order detail) which uses an empty table (temp orders) as its recordsource. The subform (datasheet view) allows me to build up a new order detail for the customer. After hit a save order button I save these order detail records to a main file I delete them from temp orders table and perform a requery which updates the subform.

This works most of the time. Occasionally though the subform record shows #Deleted Record and moving out of the field the warning "either BOF or EOF is true or the current record has been deleted". I can't find any pattern to this and it's the only thing that is stopping me from making my system live.

I have searched for this problem, but cannot find a solution. I am also curiuos to understand why when I remove the form requery that although the underlying table is correctly updated the form still shows the records for a short period, but after 5/10 seconds the subform appears to refresh itself and the order details are redisplayed as #Deleted.

I am obviously not understanding something here and would appreciate some guidance.
 
What seems to happen is that the deletion of the records is not "immediate" (is this database working in a net?. That could explain that delay). What you can do it's not to refresh the subform till been sure that the deletion has been finished and the new recordset updated.
When clicking the "save" button, try to start freezing the application window with an "echo=false"; after the requery do a ".refresh" for the subform, and finally refresh also the application window with an echo=true.
I hope it works...
 
Hi

I am just running this programme on a stand alone PC to produce this result.

I'll try your suggestion and see waht happens. I'll do this tomorrow
 

Users who are viewing this thread

Back
Top Bottom