ApplyFilter to Form

  • Thread starter Thread starter Curt
  • Start date Start date
C

Curt

I'm trying to program a command button to apply a filter
to a form based upon input from a list box. I'm able to
get it to work by specifying the filter parameter in the
code, but I can't get it to take it from the list box
control. Need help figuring this out! Here's the code I
have right now:

Private Sub Command58_Click()

DoCmd.ApplyFilter, "group1 = Forms!Test!List65"

End Sub

Where group1 is the name of the field I'm filtering
against, Test is the name of the form, and List65 is the
name of the control.
 
Hi,


Are you sure your list has "a" value? A multi-selection list does not
(well, it does, it returns Null, not the selection).


Hoping it may help,
Vanderghast, Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top