L
Laurel
I find that reports sometimes get "stuck" with filters that are applied in
VB scripts - probably from irregular exits, or maybe working while in
development mode? Dunno. I would like to refresh the filters before
opening the reports. How can I do that.
Also, I don't understand why the following script wouldn't wipe out that
filter that I find in "properties" on the report, but it doesn't seem to.
If I don't open properties and delete the spurious filter, I get no rows
returned in my report, even thought the following ls_filter has a good
value, and works once the filter property is cleared.
Private Sub Report_Open(Cancel As Integer)
Dim ls_filter As String
ls_filter = "[class_code] = " & "'" &
[Forms]![frmClassAttendanceInput]![txtClass] & "'" _
& " AND [Att_Date] = " & "#" &
[Forms]![frmClassAttendanceInput]![txtDate1] & "#"
DoCmd.ApplyFilter , ls_filter
Me.FilterOn = True
End Sub
VB scripts - probably from irregular exits, or maybe working while in
development mode? Dunno. I would like to refresh the filters before
opening the reports. How can I do that.
Also, I don't understand why the following script wouldn't wipe out that
filter that I find in "properties" on the report, but it doesn't seem to.
If I don't open properties and delete the spurious filter, I get no rows
returned in my report, even thought the following ls_filter has a good
value, and works once the filter property is cleared.
Private Sub Report_Open(Cancel As Integer)
Dim ls_filter As String
ls_filter = "[class_code] = " & "'" &
[Forms]![frmClassAttendanceInput]![txtClass] & "'" _
& " AND [Att_Date] = " & "#" &
[Forms]![frmClassAttendanceInput]![txtDate1] & "#"
DoCmd.ApplyFilter , ls_filter
Me.FilterOn = True
End Sub