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

x
?
Solved

Removing Filter from a subform  (datasheet)

Posted on 2014-02-28
3
Medium Priority
?
5,172 Views
Last Modified: 2014-03-01
I have a form that has a subform.
The subform is a datasheet.
The user can use the standard "filter" funtions in the datasheet.

I need some VBA so that when I click on a button on the MAIN form ... the filters will be removed from the Subform.

How do I use VBA to remove all filters from the subform?
0
Comment
Question by:Patrick O'Dea
[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
3 Comments
 
LVL 51

Expert Comment

by:Gustav Brock
ID: 39895398
The button is already there - below the datasheet: Filter.
Just click it, and the filter is turned off.

/gustav
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 2000 total points
ID: 39895401
Me.<NameOfSubformControl>.Form.Filter = ""
me.<NameOfSubformControl>.Form.FilterOn=True
0
 

Author Closing Comment

by:Patrick O'Dea
ID: 39897123
Thanks, just perfect.

(Much friendlier for the novice users of my system)
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

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

This article describes two methods for creating a combo box that can be used to add new items to the row source -- one for simple lookup tables, and one for a more complex row source where the new item needs data for several fields.
This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

704 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