View Full Version : Using keyed data from one form to another


garyglp
10-05-2000, 11:08 AM
I am using data from some fields in one form1 that goes into another form2. This happen when a button is clicked. The forms 1&2 are linked to each other by an "autonumber field" named "number" The query uses "[Forms]![frmNewCallCUTS Form]![NUMBER]" to link the forms. This works fine as long as the first form is closed then saved opened again. I attempted to use "Save a form" in a macro for the button properties "Click on". Not wanting to close the first form1 completely. The problem is the second form comes up blank and does not show the first form's data.

Jack Cowley
10-06-2000, 05:09 PM
Try using Me.Refresh and/or Me.Requery as the first statement in the code of you button.....

HTH,
Jack

Pat Hartman
10-06-2000, 07:34 PM
The code to save the current record is:

DoCmd.RunCommand acCmdSaveRecord

Put it at the beginning of the Button's code. You were probably trying to save the form which is not the same thing.