Filter By Selection Button

Bill Bisco

Custom User Title
Local time
Today, 13:01
Joined
Mar 27, 2009
Messages
92
I tried making a command button using Microsoft's default Command Button Maker to duplicate "Filter By Selection."

I can Filter by Selection if I use the Toolbar. However, the Code from VBA does not work.

The Code Microsoft imported is:
Code:
    DoCmd.DoMenuItem acFormBar, AcForm_View, 14, , acMenuVer70
I tried searching for other topics on this issue, but didn't find an answer.

1. Why does the button on the Toolbar but not the Code work?
2. Is there any VBA Code out there that duplicates the Toolbar's Filter By Selection Button?

Any Help is Appreciated.

Sincerely,
Bill
 
Last edited:
Howzit

Try the solution provided by Uncle Gizmo - see attached. I find it quite handy for filtering large recordsets.
 

Attachments

Thanks Kiwiman,

Why does this database hide its forms and tables, and how can I unhide them?

Sincerely,
Bill
 
Last edited:
Howzit

Sorry didn't realise they were hidden - this is how I downloaded it, not sure why it is like this - been a while since I have looked at this.

To unhide:

Tools \ Options \ View tab - Check the View Hidden Objects.

The forms should then be visible.

You can then Rt click on each form and select properties - unmark the Hidden Attribute
 

Users who are viewing this thread

Back
Top Bottom