Solved

Use Built in Filters Access Form

Posted on 2014-02-20
3
311 Views
Last Modified: 2014-02-20
Hi, i would like to know if its possible to call the built-in filters which access uses for tables  \queries for forms
0
Comment
Question by:yidel718
  • 2
3 Comments
 
LVL 20

Accepted Solution

by:
GrahamMandeno earned 500 total points
ID: 39875303
I'm not sure what you mean by "call the built-in filters".  Do you mean the drop-down filters in the header cells of a datasheet view?  And you want to "call" them from VBA code?

I don't think you can do this, and it makes no sense to do it.  This filter selection mechanism is part of the user interface and requires the user to make choices.  It makes no sense to automate it from code.

Of course, you can do a similar thing through code by setting the form filter - for example:
    Me.Filter = "[DateField]>=DateSerial(Year(Date(), 1, 1)"
    Me.FilterOn = True ' show this year's records only

Open in new window

Best wishes,
Graham Mandeno [Access MVP 1996-2014]
0
 
LVL 1

Author Comment

by:yidel718
ID: 39875312
Got you, i were just lazzzzy to built one myself !
thanks
0
 
LVL 20

Expert Comment

by:GrahamMandeno
ID: 39875423
LOL!  Glad to help :-)
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
MS Access VBA Code to Include Library References 4 51
Access 2016 Query with Proper Case logic 2 35
Microsoft Access to CSV file from VBA 3 26
Access Schema 6 26
Regardless of which version on MS Access you are using, one of the harder data-entry forms to create is one where most data from previous entries needs to be appended to new records, especially when there are numerous fields and records involved.  W…
It’s the first day of March, the weather is starting to warm up and the excitement of the upcoming St. Patrick’s Day holiday can be felt throughout the world.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

830 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