M
mwest
I keep getting an error message when I try and run this: COMPILE ERROR BLOCK IF
WITHOUT END IF.
I have changed things around but nothing seems to work
Private Sub MultiOK_Click()
On Error GoTo Err_multiOK_Click
If IsNull(Forms![Find contaminant,department,date]!Contaminant) Then
If IsNull(Forms![Find contaminant,department,date]!Department) Then
If IsNull(Forms![Find contaminant,department,date]!Date) Then
DoCmd.Close acForm, "Find contaminant,department,date"
'MsgBox "oops"
Exit Sub
End If
DoCmd.OpenQuery "Retreive Selected contaminant,department,date",
acNormal, acEdit
DoCmd.OpenForm "contaminant,department,date Display"
DoCmd.Close acQuery, "Retreive Selected contaminant,department,date"
DoCmd.Close acForm, "Find contaminant,department,date"
DoCmd.SelectObject acForm, "contaminant,department,date Display"
Exit_multiOK_Click:
Exit Sub
WITHOUT END IF.
I have changed things around but nothing seems to work
Private Sub MultiOK_Click()
On Error GoTo Err_multiOK_Click
If IsNull(Forms![Find contaminant,department,date]!Contaminant) Then
If IsNull(Forms![Find contaminant,department,date]!Department) Then
If IsNull(Forms![Find contaminant,department,date]!Date) Then
DoCmd.Close acForm, "Find contaminant,department,date"
'MsgBox "oops"
Exit Sub
End If
DoCmd.OpenQuery "Retreive Selected contaminant,department,date",
acNormal, acEdit
DoCmd.OpenForm "contaminant,department,date Display"
DoCmd.Close acQuery, "Retreive Selected contaminant,department,date"
DoCmd.Close acForm, "Find contaminant,department,date"
DoCmd.SelectObject acForm, "contaminant,department,date Display"
Exit_multiOK_Click:
Exit Sub