[AccessD] Filter on Sub-Report

Rocky Smolin - Beach Access Software bchacc at san.rr.com
Tue Aug 17 14:18:29 CDT 2004


Gustav:

Well, that worked - copying the sql text into the _Open event of the
sub-reports and then adding the 'HAVING' clauses (these are summation
queries) then appending the ORDER BY clause.

But I'm still curious why I can;'t seem to set the filter on a sub-report.
Is this the case?  And is there a workaround?

Finally, when you modify the query which is the record source of  the
sub-report by adding parameters (using querydef, I assume?), do you have to
unset the parameters the next time you run the report if the user has not
selected any filtering?

Thanks for your help,

Rocky Smolin
Beach Access Software
http://www.e-z-mrp.com


----- Original Message ----- 
From: "Rocky Smolin - Beach Access Software" <bchacc at san.rr.com>
To: "Access Developers discussion and problem solving"
<accessd at databaseadvisors.com>
Sent: Tuesday, August 17, 2004 11:32 AM
Subject: Re: [AccessD] Filter on Sub-Report


> Gustav:
>
> Mostly because I've always done it the other way and never learned how to
> apply the filters directly to the queries.  I have set the recordsource in
a
> report by modifying the SQL statement that represents the query.  Guess
I'll
> try that.
>
> Thanks,
>
> Rocky
>
> ----- Original Message ----- 
> From: "Gustav Brock" <gustav at cactus.dk>
> To: "Access Developers discussion and problem solving"
> <accessd at databaseadvisors.com>
> Sent: Tuesday, August 17, 2004 11:21 AM
> Subject: Re: [AccessD] Filter on Sub-Report
>
>
> > Hi Rocky
> >
> > Why don't you apply the filter to the queries which drive the
> > subreports?
> >
> > /gustav
> >
> >
> > > I have two reports with two different record sources which I have
placed
> on another report.  So they're sub-reports but not linked parent-child to
> the main report.
> >
> > > Each runs okay standalone, but when I run the main report with the two
> sub-reports on it it blows up on the statement Me.Filter = ""; says the
> setting you entered isn't valid for this property.
> > > Same with Me.FilterOn = False.
> >
> > > These statements are in the _Open event of the sub-report, preparatory
> to creating a filter from the user's selected options on the form which
> calls the report.
> >
> > > Anyone know why I can't set the filter on the sub-report?
> >
> > -- 
> > _______________________________________________
> > AccessD mailing list
> > AccessD at databaseadvisors.com
> > http://databaseadvisors.com/mailman/listinfo/accessd
> > Website: http://www.databaseadvisors.com
> >
>
> -- 
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>




More information about the AccessD mailing list