Connecting Tech Pros Worldwide Forums | Help | Site Map

Combo box question

Newbie
 
Join Date: Jun 2006
Posts: 3
#1: Jun 27 '06
Is it possible to allow users to select multiple values in a combo box form? I was able to do it with a list box, but the form is designed to run a query and I couldn't get the query to look for multiple values for that field. Any help would be appreciated. Thanks!

Kara

Newbie
 
Join Date: Jul 2006
Posts: 4
#2: Jul 16 '06

re: Combo box question


oh my friend there only one main difference in list box and combo box ie. in list box we can select multiple values but not in combobox.


if u help me for this question i m very thank full to u.

how to create list box with three item,when we click 1 item then form one open,if we click 2 item then form 2 open and soon plz reply soon
Familiar Sight
 
Join Date: Jun 2006
Location: Edmonton, AB
Posts: 179
#3: Jul 17 '06

re: Combo box question


It is possible to do this as long as the values come from the same table, using a piece of code called "SELECT DISTINCTROW". You enter the code in the "Row Source" field under the properties of the combo box.

For example, a database that I created has a table called "tblrefPartsList", and a couple of the fields in that table are called "PartID", and "refPart". The code would be:

SELECT DISTINCTROW [tblrefPartsList].[PartID], [tblrefPartsList].[refPart],FROM [tblrefPartsList];

This is not the main table however. This table is just used to put values into another table (i.e the values that are in the tblrefPartsList table will go into a field in another table). To set where the value will go, bound the combobox to a field in your main table, using "Control Source" under properties.

comteck
Reply


Similar Microsoft Access / VBA bytes