I'm trying to filter a subform based on a checkbox on my main form. My main forms name is frmCrewInfo, and the subforms name is subCrewDocs. I'm trying to filter the subform by a field called IsActive which utilizes a checkbox (true/false) field on the form. I'm attempting to use the .Form.Filter property.
Here is what I have written
Code:
Private Sub chkShow_Click()
If Me.chkShow = True Then
Me.[subCrewDocs].Form.FilterOn = False
Else
Me.[subCrewDocs].Form.Filter = "IsActive = 'Yes'"
Me.[subCrewDocs].Form.FilterOn = True
End If
End Sub
I get the following:
"Run Time Error '2645": Vessel Matrix can't find the field '|1' referred to in your expression.
This seems very odd because i have not typed a vertical bar and a one anywhere in the procedure or module as the message states. I can't figure out what the heck is going on here. Very bizarre!
Any thoughts?