I have following forms:
frmSHE - parent
frmSHEMain- first sub form
frmSHEMainSF - second sub form
frmPerson - a sub form of frmSHEMainSF
I am trying to use a value within the frmSHEMainSF to ensure that users after selecting an incident type always fill a field (name) on the frmPerson using the before update event in this form.
I have used the following systax but it does not quite work. Will appreciate some help.
If Me.IncType = " Incident Resulting in Injury" And IsNull(Forms!frmSHE!frmSHEMain.Form!frmSHEMainSF.Form!frmPerson.Name) Then
MsgBox "You must enter personal details to create this incident!"
Cancel = True
frmPerson.Name.SetFocus
Exit Sub
End If
frmSHE - parent
frmSHEMain- first sub form
frmSHEMainSF - second sub form
frmPerson - a sub form of frmSHEMainSF
I am trying to use a value within the frmSHEMainSF to ensure that users after selecting an incident type always fill a field (name) on the frmPerson using the before update event in this form.
I have used the following systax but it does not quite work. Will appreciate some help.
If Me.IncType = " Incident Resulting in Injury" And IsNull(Forms!frmSHE!frmSHEMain.Form!frmSHEMainSF.Form!frmPerson.Name) Then
MsgBox "You must enter personal details to create this incident!"
Cancel = True
frmPerson.Name.SetFocus
Exit Sub
End If