Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Modifying subform filters

Status
Not open for further replies.

arthurbr

Technical User
Nov 6, 2003
231
0
0
BE
Depending on user's input I need to change the filter value of a subform when opening the form.
How can this be done using macro's ?

Thx for your help

André
 
Hi,

How will the users input affect the filter of the subform? What do they specify?

You should be able to just change the Where Condition part of the Macro using the Apply Filter action.

Also any particular reason why you want to use Macros instead of VBA? In 4-5 years using Access I have never used Macros. (Except AutoExec to Run Code). You can do it all and much more in VBA.

Dean.
 
Hello Dean,
the users actually choose what they want to see with a switchboard , f.i. see all the fields or a subset ( no real input, just a choice).
I tried the applyfilter but it only affects the main form and not the subform although it is this one which I need to filter.
A for using macros, they look easier for the beginner I am.
 
So is this switchboard on the same form as the data, or a different one?

Assuming it must be the same one to link to the macro.
 
No, switchboard is a different forms and selecting an option triggers a macro
 
hello there,
sure using MAcros is much easier as a beginning esp. if u don't know VBA..
now sure the applyfilter is correct, but u must be LINKING the subform with the form & do a refresh command.
Jinan74
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top