Remove Filter

G

Guest

I have a combo box with the source of table.id, table.name. I want to filter
by selecting table.name where table.id=form.id. The filter works just fine,
but when I remove the filter using the code

Private Sub RemoveFilter_Click()
Me.Filter = ""
Me.FilterOn = False
End Sub

and then try to filter again using a new selection, the filter does the
first one I selected instead of the new one.

Thanks in advance for your help.
 
G

Guest

Why do you not just get rid of
Me.Filter =""
and go with

Me.FilterOn = False

to remove the filter.
--
Bob Larson
Access World Forums Super Moderator
Utter Access VIP
Tutorials at http://www.btabdevelopment.com
__________________________________
If my post was helpful to you, please rate the post.
 
G

Guest

Hi Bob -
I think I wasn't clear. When I apply the filter the first time it works
(show companies where sales person x is assigned). When I remove the filter,
it also works (shows all companies). The problem comes in when I try to
filter for a different sales person y - it shows companies for sales person x
instead of sales person y. the filter is from a combo box where the sales
person id is hidden (width 0), but is also the bound column.
 

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