I'm not exactly sure what you're trying to do. Are you Opening the report
and checking the box? or is the value already checked and you are filtering
off that?
If the latter then the record source of the report should take care of that,
just check for a 0 or "no" value in criteria of the query.
Dan Johnson <djo...@home.com> wrote in message
news:eK2S9Pze#GA.266@cppssbbsa03...
Remove filtering from the report properties and code.
Also, let the query to return all records. You apply
a filter/search in VBA by passing the where clause
in the OpenReport method of DoCmd object.
To open the report from a button click use:-
Dim stDocName As String. stSQL
stDocName = "Report"
stSQL = '[Query].boolean=0'
DoCmd.OpenReport stDocName, acPreview, , stSQL
Best way to experiment using the above method is to
create a form and report that use the same query. (make
sure your table definition has the lookups defined). Use
the on form filter function of access to create the where
clause that you require in your report. You can preview
your results in the form itself.
to see the where clause + create the report use.
Dim stDocName As String
Msgbox Form.Filer
stDocName = "SPEC_CHANGES"
DoCmd.OpenReport stDocName, acPreview, , Form.Filter
Dan Johnson wrote in message ...
Instead of using Yes/No for your filter, try using "1" for yes and "0" for no.
Hope this helps
Robert Cooper
Robert Cooper <robert...@NOSPAMeasiwipes.demon.co.uk> wrote in message
news:3709EB9F...@NOSPAMeasiwipes.demon.co.uk...