Update field on one form from nother

  • Thread starter Thread starter Andrew @ CrazyCritters
  • Start date Start date
A

Andrew @ CrazyCritters

Hi,

I have a form 'Frm_New_Booking'. On it I have a button to open another form
with a calendar on it so the user can select a date. The result ends up in a
variable 'The_Date'. There is a button on the form to close the form. I
want the value of the variable 'The_Date' to be placed in field 'DOB" On
'Frm_New_Booking'.

Please advise.

Andrew
240508
 
Hi

There are other ways to do but I would just add a line of code to close
button on your calender form t set the alue of The_Date on the new booking
form (This only works if both forms are open). If you have closed New
Booking form, post back for a slightly different code


Private Sub ButtonName_Click()
Forms!Frm_New_Booking!DOB = Me.The_Date
DoCmd.Close
End Sub
 
Back
Top