I feel like the answer is staring at me but I can't figure it out.
I have a number of reports to create based on different dates. Since the dates are confusing, I made a table that looks a little like this (of course I simplified it)
Reporting Month ... Start Date ... End Date
Jan ... 01/01/06 ... 01/31/06
Feb ... 02/01/06 ... 02/28/06
Then I made a form based off of that table so the user can use a combo box, drop down to the reporting month and all the dates are put in the fields automatically.
I've done good so far so I went back to test it and it works except for one minor detail. If I were to scroll through the records using the Record Selectors, the dates move along the records the the combo box doesn't.
I looked at the event procedure (because I just used the wizard to create the combo box) and this is what is says on "After Update"
Private Sub Combo31_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[Reporting_Month] = '" & Me![Combo31] & "'"
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Can someone point me in the right direction to get the combo box to move along the records like the dates do? Thank you.
I have a number of reports to create based on different dates. Since the dates are confusing, I made a table that looks a little like this (of course I simplified it)
Reporting Month ... Start Date ... End Date
Jan ... 01/01/06 ... 01/31/06
Feb ... 02/01/06 ... 02/28/06
Then I made a form based off of that table so the user can use a combo box, drop down to the reporting month and all the dates are put in the fields automatically.
I've done good so far so I went back to test it and it works except for one minor detail. If I were to scroll through the records using the Record Selectors, the dates move along the records the the combo box doesn't.
I looked at the event procedure (because I just used the wizard to create the combo box) and this is what is says on "After Update"
Private Sub Combo31_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[Reporting_Month] = '" & Me![Combo31] & "'"
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Can someone point me in the right direction to get the combo box to move along the records like the dates do? Thank you.
Last edited: