Combo box and Select all

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all
I have a combo box on a form which allows me to filter by the selected value
in the dropdown list. The current SQL string is "SELECT
tbl_WhereSeen.WhereSeen FROM tbl_WhereSeen ORDER BY tbl_WhereSeen.WhereSeen; "

How do I include in the dropdown list an item that selects all items.

TIA

johnb
 
Hi all
I have a combo box on a form which allows me to filter by the selected value
in the dropdown list. The current SQL string is "SELECT
tbl_WhereSeen.WhereSeen FROM tbl_WhereSeen ORDER BY tbl_WhereSeen.WhereSeen; "

How do I include in the dropdown list an item that selects all items.

TIA

johnb


Note that the symbols <> surround the word "All". That is to have the
list sort with the word <All> at the top of the list before any other
"A" listing.

First add "<All>" to the drop down list.
As Combo box Rowsource:

"SELECT tbl_WhereSeen.WhereSeen FROM tbl_WhereSeen
Union Select "<ALL>" from tbl_WhereSeen
ORDER BY tbl_WhereSeen.WhereSeen; "

Then if you are using the Whereseen to filter data on,
change the query criteria to:

Like
IIf([forms]![FormName]![ComboName]="<ALL>","*",[forms]![FormName]![ComboName])
 
Back
Top