Hi,
I have a database which contains user contact information. I have a form where a user can press a button to bring them to a form which allows them to view any other user's contact information. When the button is pressed, a pop-up form appears prompting the user to select a name from the drop down box. The user would select a name from the combo box, hit ok and it should bring up the main contact information form which populates with the chosen user's information. For example, let's say John Doe is using the database. He wants to look up Jane Doe's contact information. He presses the button to initiate the search which brings up the selection pop-up form. John selects Jane Doe from the combo box and presses ok. The form should then open the contact information form and requery the form to populate with Jane's information. Right now the issue that I am having is that the form will not requery to the selected user's information. The sample code I am using on the ok button is as follows
Code:
Private Sub cmdUserSelectGO_Click()
'opens user information form to queried to selected user's information
If IsNull(cmbUserSelect) Then
MsgBox ("Please select aname from drop down box")
Else
DoCmd.OpenForm"frmUserInfo"
Me.frmUserInfo.Form.Requery
End If
End Sub
What i can't figure out is why the code I am using will not requery to the selected person's information. As I mentioned previously, this sample piece of code is attached to the ok button the pop-up form under the on click event.