
Insert before afterUpdate()
Looking at your other post, you are using the AfterUpdate event of the
location combo to open the form. If you want the location record to be saved
first, you can explicitly save the record either by using docmd.RunCommand
acCmdSaveRecord, or by setting the Dirty propety of the form to false (this
forces an update)
docmd.RunCommand acCmdSaveRecord
'Or
me.dirty=false
--
Sandra Daigle
[Microsoft Access MVP]
For the benefit of others please post all replies to this newsgroup.
Quote:
> Hi all,
> I have two forms - frmLocation(main form) and frmData. No
> subforms present.
> After all the data is entered in frmLocation, there is a
> list box in frmLocation selecting whose value takes me to
> frmData as an AfterUpdate event.
> How do I add the existing data in frmLocation to the
> database ( table LOCATION) before the frmData is loaded.
> Thanks for your help
> Dan