Sub Form

S

Simonglencross

I have a main customer form which has a subform called frmappointmententry
which is used for appointment entry, I also have another sub form called
frmappointmentdisplay. When I add an appointment and then click on the tab
for the display they appointment will not appear unless I come out and back
in to the Main Form. I know I ahve to enter the code Me.requery and I have
tried this in a few areas with no success i.e beforeupdate, after update, on
focus etc (on the Appoinmentdisplayform) could someone please point me in
the right direction.

Kind Regards


Simon
 
W

Wayne Morgan

When you exit the subform, the record you just changed is saved to the file.
Try

Me.Dirty = False

to save the record then requery, if needed.

Also, just a hint, instead of "frmappointmententry", "frmAppointmentEntry"
would be much easier to read.
 
Top