Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Appl/Remove Filter/Sort

Posted on 1998-04-22
4
Medium Priority
?
211 Views
Last Modified: 2012-05-04
Using the FilterOn property of a form, I can tell if a form displays filtered data or not. How can I tell if the user has sorted the data or not; for example how can I tell if the user has clicked on one of the toolbar sort buttons?

Thanks
0
Comment
Question by:rmk
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 17

Expert Comment

by:ramrom
ID: 1955872
Examine the form's OrderBy property.
0
 

Author Comment

by:rmk
ID: 1955873
My tests indicate that your suggestion won't do the trick. For example: 1) open a form with a blank order by property, 2) use the tool bar sort button and the order by property gets a value, 3) remove the filter / sort using the menu bar or shortcut menu for the form to restore the form to its recordsource sort and the order by property does NOT get cleared; so at this point I can't tell if the form is in some user specified sort or not.
0
 
LVL 17

Accepted Solution

by:
ramrom earned 400 total points
ID: 1955874
Sorry; you should examine OrderBy and OrderByOn. The most recent filter/sort is saved in OrderBy. It is in effect only when OrderByOn is true. If the user removes filter/sort OrderByOn goes false.
0
 

Author Comment

by:rmk
ID: 1955875
Thanks! I wasn't aware of the OrderByOn property.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
Instead of error trapping or hard-coding for non-updateable fields when using QODBC, let VBA automatically disable them when forms open. This way, users can view but not change the data. Part 1 explained how to use schema tables to do this. Part 2 h…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question