Johnnyw
10-05-2001, 05:57 AM
I have a main form that has a field called "product code" and a button. When I click the button, it opens another form with the details of the "product code." When I fill in the field "product code" on the main form, I want the same code to show up in the details form without me having to retype the same code. Thanks for your help.
Jack Cowley
10-05-2001, 07:19 AM
In the On Open event of the second form put code similar to this:
Me.ProdCode = [Forms]![FirstFormName]![ProdCodeFieldName]
Do not close the first form or this will not work. If you do close the first form then search help for the OpenArgs argument....
Johnnyw
10-05-2001, 10:41 AM
Thanks! The code worked but I put it in the on enter event of the Product code field in the second form because when i had it in the on open event of the second form it was giving me an error.