After Update, After Insert

  • Thread starter Thread starter cefrancke
  • Start date Start date
C

cefrancke

I'm trying to update some combo boxes and subform data (including their

combo boxes too.) after inserting a record into a different subform.

I insert a record into subformA (tableA is underlying).
The After Update(AU) event fires, the AU code inserts a record into
tableB, then it requerys all related combo boxes, subformB (tableB is
underlying) and subformB combo boxes.


This works for one record, however all requeries fail (that is, they
have no effect).
AND....the amount of records in tableB is one short of what it should
be.


Any ideas?


TIA
 
It sounds like you haven't actually saved the record in subform B.
Make sure you do that and then add a line

me.refresh

in both forms either when all done adding records or when each record
is added.

HTH
 
I'm trying to update some combo boxes and subform data (including their

combo boxes too.) after inserting a record into a different subform.

I insert a record into subformA (tableA is underlying).
The After Update(AU) event fires, the AU code inserts a record into
tableB, then it requerys all related combo boxes, subformB (tableB is
underlying) and subformB combo boxes.


This works for one record, however all requeries fail (that is, they
have no effect).
AND....the amount of records in tableB is one short of what it should
be.

Please post your code.

John W. Vinson[MVP]
 
My apologies,
I meant to say that upon MULTIPLE record inserts, that is,
pasting more than on record at a time,
the requeries fail, etc as before.

So, for one record the requeries apparently work for combos,
subforms and subform combos.

On pasting multiple records, it doesn't work.

TIA
 
My apologies,
I meant to say that upon MULTIPLE record inserts, that is,
pasting more than on record at a time,
the requeries fail, etc as before.

So, for one record the requeries apparently work for combos,
subforms and subform combos.

On pasting multiple records, it doesn't work.

TIA

How are you "pasting" (and for that matter, why are you pasting rather
than running an Append query, which is much more efficient)?

Again... please post your code. You may be doing nothing wrong
(perhaps the insertion operation hasn't completed??) but since we
don't know what you're doing, there's no way to tell.

John W. Vinson[MVP]
 
Back
Top