Search Criteria - Yes/No - Allen Browne Form Example

B

Billp

Hi,
Not sure if anyone is familiar with this application - wonderful piece of
useful that has saved many a problem for searching.
Not sure if this question out of left field can be done - here goes,

In the example of the yes/no.

Say I have series of check boxes that represent Sales people
DK
SS
MM
NM
TW

On one line. And I want to be able to search for the lines that have TW.

Is it possible to have the combobox as a drop down that has these initials
in it - and once selected it looks at the 5 checkboxes and filters only that
which is selected.
Its a space problem I have and a need to do something like it. In fact the
checkboxes number 12 and for space I have made them not visible and hidden
them behind other fields on the line. I don't want to have 12 combo boxes.

Any ideas and pointers on coding really really appreciated
 
A

Allen Browne

So you have 5 check boxes (one for each sales person) in your table.
On your form you want to put 5 *unbound* check boxes.
If the user checks a box, you want to filter the form on that person only.

Assuming:
a) you are building the filter string using code like the one in this
example:
http://allenbrowne.com/ser-62.html
b) the 5th check box is named check5 and applies to the TW field,
then the code would look like this:

If Me.check5.Value Then
strWhere = strWhere & "([TW] = True) AND "
End If
 

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

Top