Access Help with Filter by Form

Copper Contributor

Hi there,

 

I am trying to discover how to invoke a "Filter by Form" command in a macro or via vba. What I want to do is add a button to a form that will invoke the Filter by Form function, without clicking the command in the ribbon...is this possible? 

 

Any hints gratefully accepted...

1 Reply

@AccessAdam In the click event of a button

Me.Filter = "SomeField = 'SomeValue'"

Me.FilterOn=True