Hi Experts, am new to access. I juts created a form with sub form based on two tables having 1: many relationship.
The main form is from tblStudents and subform is from tble attendance.
First on main form I choose student name from a combo box and records for that student is displayed on the subform in form view.
1.*
The same
Ok now on the subform ( Form view) I have another combo to display records based on dates selected.
2*
Problem is that code#2 is not working..maybe because code one is filtering so code is refusing to filter as well. I do not know what to do.. ANy help will be appreciated.
Thanks
Rozeanna
The main form is from tblStudents and subform is from tble attendance.
First on main form I choose student name from a combo box and records for that student is displayed on the subform in form view.
1.*
Code:
Private Sub Combo14_AfterUpdate() ' Find the record that matches the control. Dim rs As Object Set rs = Me.Recordset.Clone rs.FindFirst "[StudentID] = " & str(Nz(Me![Combo14], 0)) If Not rs.EOF Then Me.Bookmark = rs.Bookmark DoCmd.GoToControl "Command12" End Sub
Ok now on the subform ( Form view) I have another combo to display records based on dates selected.
2*
Code:
Private Sub Combo12_AfterUpdate() ' Find the record that matches the control. Dim rs As Object Set rs = Me.Recordset.Clone rs.FindFirst "[TimeSheetId] = " & str(Nz(Me![Combo12], 0)) If Not rs.EOF Then Me.Bookmark = rs.Bookmark End Sub
Thanks
Rozeanna
Comment