View Full Version : Saving records when opening a new form


battenberg
12-11-2006, 06:02 AM
Hi

In my database I have certain fields which when dbl clicked move me to a new form. What code should I be researching to make sure that the forms field values are committed to the tables before opening the new form??

is it: docmd save or a recordset.update?

thanks

freakazeud
12-11-2006, 06:07 AM
Hi,
you could try:

If Me.Dirty = True Then Me.Dirty = False

HTH
Good luck

battenberg
12-11-2006, 08:26 AM
is that a save command.. what does it mean?

freakazeud
12-11-2006, 08:31 AM
Hi,
Foms have a dirty property which can be set to false if it is true to force a record save to the underlying data source.
HTH
Good luck

battenberg
12-11-2006, 08:33 AM
thankyou very much...
I can put this in the dbl click event of a field before it opens a new form?

freakazeud
12-11-2006, 08:39 AM
Sure...
You're welcome.
Good luck on future projects!