I have two forms: "Job Sheet" (the main form) and "Jobs sub" (the subform).
I'm trying to use the 'afterupdate' function with an unbound textbox called yrcheck to filter the datasheet view of the subform, by the JbYr field.
Please tell me, what's wrong with this code?
Private Sub yrcheck_AfterUpdate()
Dim yr As Integer
yr = Me.yrcheck
[Jobs sub].Form.Filter "JbYr='" & yr & "'"
[Jobs sub].Form.FilterOn = True
End Sub
I get "Invalid Use of Property" as an error.
What's wrong?