I have FORM#1 which is populated from Table 1 and field - PART_NUM on this form has a combo box which can automatically populate the entire form when the correct PART_NUM is choosen. However, if the user does not know the proper PART_NUM that they are looking for, I have a CHOOSE PART# button which when clicked pulls up another FORM #2 which has information from Table 2 (Part # and Part_Name and Comments). These two tables are linked. When the user figures out which PART_NAME corresponds to the PART_NUM that they are searching for, they chose that PART_NUM and press a button#2 I've created which in turn fills in the Part_Num in FORM #1.
In the OnClick property of button#2 I've placed this code to make the two table link when clicking the button:
FORM![TABLE1]![PART_NUM] = Me.PART_NUM
and it works great.
I also used this piece of code just as a tester to see if one of the other fields could be populated using the same button:
FORM![TABLE1]![D1] = FORM1[TABLE1]![D1]
and it also worked great at 1st leading me to think that I had my solution for all the other fields I needed to auto-populate in FORM#1 but then it crapped out on me and I'm stuck in a rut because I have no idea how to populate the entire FORM#1 using button#2 in FORM#2. Hopefully my problem is clearly defined and hopefully someone can help me out.
Thanks
In the OnClick property of button#2 I've placed this code to make the two table link when clicking the button:
FORM![TABLE1]![PART_NUM] = Me.PART_NUM
and it works great.
I also used this piece of code just as a tester to see if one of the other fields could be populated using the same button:
FORM![TABLE1]![D1] = FORM1[TABLE1]![D1]
and it also worked great at 1st leading me to think that I had my solution for all the other fields I needed to auto-populate in FORM#1 but then it crapped out on me and I'm stuck in a rut because I have no idea how to populate the entire FORM#1 using button#2 in FORM#2. Hopefully my problem is clearly defined and hopefully someone can help me out.
Thanks