Q
quaddawg via AccessMonster.com
I apologize in advance for the longwindedness of this post, but I can't for
the life of me figure out the problem so I'll err on the side of providing
too much info. Also, this might be nearly impossible to diagnose this way,
but if anything strikes you as strange or wrong, please let me know.
I have a data entry form with a command button that launches a search
dialogue box containing unbound search boxes. I have a search button on the
search form coded to open (reopen?) the entry form while applying a filter
consisting of a query running off the search entry form. (The query is now
displayed in design or sql view with an insane number of permutations, I'm
guessing due to the original design allowing null values in the unbound
search fields).
The code of the search button reads in pertinent part:
DoCmd.OpenForm "frmMembershipEntryForm", acNormal, "qryMembershipFormSearch2"
I added a command button on the entry form that cleared the filter using:
Me.FilterOn = False
This worked fine for awhile; the form would open, filtered by the query.
Pushing the clear filter button would remove the query filter, displaying all
results.
Today, for no apparent reason, the search button would open the form with no
noticeable filtering.
Some things I've noticed, relevance unknown:
While before the form would indicate, next to the record selector buttons, "
(Filtered)", it no longer does.
The filter funnel icon on the menu is grayed out when the form opens.
The form's properties are set to allow filters, but where the filter line
used to have at least some of the language of the fitlering query is now
blank.
To diagnose, I added a DoCmd.OpenQuery "qryMembershipFormSearch2", etc. to
the Search button and the proper results display in the query, but the Entry
Form still opens with no filter applied.
I would greatly appreciate any insights you might have as to the sudden
(can't be random, I know) inapplicability of the filter.
Further, I'd love suggestions for the proper application of filtering queries
to forms through coded buttons.
Thanks for your help!
the life of me figure out the problem so I'll err on the side of providing
too much info. Also, this might be nearly impossible to diagnose this way,
but if anything strikes you as strange or wrong, please let me know.
I have a data entry form with a command button that launches a search
dialogue box containing unbound search boxes. I have a search button on the
search form coded to open (reopen?) the entry form while applying a filter
consisting of a query running off the search entry form. (The query is now
displayed in design or sql view with an insane number of permutations, I'm
guessing due to the original design allowing null values in the unbound
search fields).
The code of the search button reads in pertinent part:
DoCmd.OpenForm "frmMembershipEntryForm", acNormal, "qryMembershipFormSearch2"
I added a command button on the entry form that cleared the filter using:
Me.FilterOn = False
This worked fine for awhile; the form would open, filtered by the query.
Pushing the clear filter button would remove the query filter, displaying all
results.
Today, for no apparent reason, the search button would open the form with no
noticeable filtering.
Some things I've noticed, relevance unknown:
While before the form would indicate, next to the record selector buttons, "
(Filtered)", it no longer does.
The filter funnel icon on the menu is grayed out when the form opens.
The form's properties are set to allow filters, but where the filter line
used to have at least some of the language of the fitlering query is now
blank.
To diagnose, I added a DoCmd.OpenQuery "qryMembershipFormSearch2", etc. to
the Search button and the proper results display in the query, but the Entry
Form still opens with no filter applied.
I would greatly appreciate any insights you might have as to the sudden
(can't be random, I know) inapplicability of the filter.
Further, I'd love suggestions for the proper application of filtering queries
to forms through coded buttons.
Thanks for your help!