By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,741 Members | 1,973 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,741 IT Pros & Developers. It's quick & easy.

Acc97 Advanced Filter - Capturing the Filter for report Filter

P: n/a
I have a form Form1 which when the Advanced Filter/Sort is used
creates a form(maybe) with a title 'Form1Filter1 : Filter'. When I
apply the filter to Form1 it is applied, but the value of Form1.Filter
is ''.

How do I obtain the Advanced Filter/Sort criteria as a string ?

I cannot reference the object 'Form1Filter1 : Filter' by using
Form1Filter1.

thanks in advance.
Nov 13 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
In code use:

Me.filter
So if you wanted a report to display what you have filtered on a form, you
could use:
FilterOn = True
Me.filter = forms!formname.form.filter

HTH
Paul
"Mike Sweetman" <ac******@sweetman.force9.co.uk> wrote in message
news:48**************************@posting.google.c om...
I have a form Form1 which when the Advanced Filter/Sort is used
creates a form(maybe) with a title 'Form1Filter1 : Filter'. When I
apply the filter to Form1 it is applied, but the value of Form1.Filter
is ''.

How do I obtain the Advanced Filter/Sort criteria as a string ?

I cannot reference the object 'Form1Filter1 : Filter' by using
Form1Filter1.

thanks in advance.

Nov 13 '05 #2

P: n/a
Thanks Paul

Moments after the post (I was at my wits end) I realised that the
problem was that my 'filter' was actually only setting the value of
me.orderby because that was what I was doing - using the advanced
filter/sort to reorder my data. Hence the me.filter was '' because I
had not set any criteria in this aspect of the advanced filter.

"Paul" <pz****@rogers.com> wrote in message news:<j9********************@rogers.com>...
In code use:

Me.filter
So if you wanted a report to display what you have filtered on a form, you
could use:
FilterOn = True
Me.filter = forms!formname.form.filter

HTH
Paul
"Mike Sweetman" <ac******@sweetman.force9.co.uk> wrote in message
news:48**************************@posting.google.c om...
I have a form Form1 which when the Advanced Filter/Sort is used
creates a form(maybe) with a title 'Form1Filter1 : Filter'. When I
apply the filter to Form1 it is applied, but the value of Form1.Filter
is ''.

How do I obtain the Advanced Filter/Sort criteria as a string ?

I cannot reference the object 'Form1Filter1 : Filter' by using
Form1Filter1.

thanks in advance.

Nov 13 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.