Clear Filters with code


R

R. Choate

I use code to filter records when an entry is chosen from a cbobox. I need to be able to clear the filter as well. I know I can get
it to showallrecords, but if I close the form and look at its properties, I still see the filter I applied earlier. How can I clear
the filter altogether?

Thanks in advance !
 
Ad

Advertisements

D

Dirk Goldgar

R. Choate said:
I use code to filter records when an entry is chosen from a cbobox. I
need to be able to clear the filter as well. I know I can get it to
showallrecords, but if I close the form and look at its properties, I
still see the filter I applied earlier. How can I clear the filter
altogether?

Thanks in advance !

The statement

Me.FilterOn = False

turns off the filter (same as DoCmd.ShowAllRecords), while

Me.Filter = ""

clears the Filter property.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top