• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1097
  • Last Modified:

Remove filter/sort

how would i write this in a function so it does what the remove filter/sort button in access does ... i need it to work exactly like it does in access
0
NEWJACK
Asked:
NEWJACK
  • 2
  • 2
  • 2
1 Solution
 
abaldwinCommented:
Are you saying that you have a report or some other container that displays with a filter and you want to remove that filter in code??????

I am not sure that I understand your question.

Andy
0
 
abaldwinCommented:
Are you saying that you have a report or some other container that displays with a filter and you want to remove that filter in code??????

I am not sure that I understand your question.

Andy
0
 
NEWJACKAuthor Commented:
i have a form that pulls from a table ... i have the table filtered to bring back information in a certain manner ... the user is going to update the records from this form and the only button that seems to update and filter the table after changer have been made is the remove filter/sort button on the menu bar ... i would like to have a command button on the form that does the same.
0
Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
mgrattanCommented:
In your command button you could issue the following code:

DoCmd.ShowAllRecords

This will remove the filter/sort.  Or, you can do this:

Me.Filter = ""
Me.FilterOn = False

To set another filter do this:

Me.Filter = "[FieldName] = 'Criteria'"
Me.FilterOn = True



0
 
NEWJACKAuthor Commented:
This works great thanks a million ... Felix
0
 
mgrattanCommented:
Felix,

glad I could help out.

Mike
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now