AFAIK, a listbox doesn't have a separate Filter property, so you'll need to
build your filter into the query which defines the listbox's rowsource.
Suppose you have an option group named gpFilter; optionvalue 1 means to
filter the (numeric) "ID" field by whatever's in the txtID control;
optionvalue 2 means no filter.
You could build your query to include a WHERE Clause like this: (Air code)
ID=Forms!MyForm!txtID OR Forms!MyForm!gpFilter=2
Then all you need to do is to requery the listbox.
Be sure you requery the listbox itself, not the form.
HTH
- Turtle
"Colleyville Alan" <ae***********@nospam.comcast.net> wrote in message
news:eFArc.2271$af3.123570@attbi_s51...
I have a listbox that is populated with info and when the user selects
categories of things from the list, it brings up detailed items from which
to choose. I want to be able to put a filter on that list that can be
driven by a radio button. The question is, how do I go about this?
I can get a radio button to execute code and the screen to refresh, but I
am not certain about how to build the filter for the list. I populate the
listbox via a query and could set a filter in the initial query process,
but then to turn the filter on and off makes the concept a bit hazy.
Anyone have an idea?
Thanks