I have a MainForm. On the MainForm there is a button when clicked it opens a popup form "Form2". Form2 record source is a query and requires the user to enter a parameter value "[EmployeeID]" before opening and populating the form. The form works great, the parameter value form pops up and the user enters the EmployeeID number and the form opens. The problem is if the user cancels the paramter value I receive a runtime error "3021" which gives the user the option of debug and end. Is there anyway to bypass this error message so it does not appear if cancelled. This the code for the onclick event on the MainForm.
[blue]Private Sub GlobeEnter1_Click()
DoCmd.OpenQuery "004)_Deletes_T200_Table"
DoCmd.OpenQuery "005)_Makes_T200_Table"
DoCmd.OpenForm "Form2", acNormal [\blue]
[blue]Private Sub GlobeEnter1_Click()
DoCmd.OpenQuery "004)_Deletes_T200_Table"
DoCmd.OpenQuery "005)_Makes_T200_Table"
DoCmd.OpenForm "Form2", acNormal [\blue]