Private Sub cmdClose_Click()
On Error GoTo Err_cmdClose_Click
DoCmd.Close
DoCmd.OpenForm "Switchboard", acNormal, , , , acDialog
Exit_cmdClose_Click:
Exit Sub
Err_cmdClose_Click:
MsgBox Err.Description
Resume Exit_cmdClose_Click
End Sub
Private Sub Form_Open(Cancel As Integer)
For Each frm In Forms
If frm.Name <> "frmBuildWSNo_Structure" Then DoCmd.Close acForm, frm.Name
Next frm
End Sub
Private Sub cmdReturnMasterWSNo_Click()
On Error GoTo Err_cmdReturnMasterWSNo_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frmBuild Master WS No"
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_cmdReturnMasterWSNo_Click:
Exit Sub
Err_cmdReturnMasterWSNo_Click:
MsgBox Err.Description
Resume Exit_cmdReturnMasterWSNo_Click
End Sub
|