K
Karen
Hi,
I have a form that is opened from another form to capture info about a new person. On the calling form, there is a combobox with 'New' and if it is selected I open a person input form to capture information on the new person.
On the person input form I have an 'Exit' button to close the form with this code behind it
Private Sub cmdExit_Click()
On Error GoTo Err_cmdExit_Click
strNewAgent = txtFullName.Value
DoCmd.Close
Exit_cmdExit_Click:
Exit Sub
Err_cmdExit_Click:
MsgBox Err.Description
Resume Exit_cmdExit_Click
End Sub
When the input form closes, so does the form that called it. Why is this happening?
I have a form that is opened from another form to capture info about a new person. On the calling form, there is a combobox with 'New' and if it is selected I open a person input form to capture information on the new person.
On the person input form I have an 'Exit' button to close the form with this code behind it
Private Sub cmdExit_Click()
On Error GoTo Err_cmdExit_Click
strNewAgent = txtFullName.Value
DoCmd.Close
Exit_cmdExit_Click:
Exit Sub
Err_cmdExit_Click:
MsgBox Err.Description
Resume Exit_cmdExit_Click
End Sub
When the input form closes, so does the form that called it. Why is this happening?