Selecting multiple values in a pick list?

A

AccessQuestion

Probably a simple question. But I'm trying to creat a
list/combo box in a table and I want the data entry
operator to be able to choose multiple values from the
list. How Can I allow multiple values?

Thank you so much.
 
D

Douglas J. Steele

You can't for a combo box.

If you set MultiSelect property for a list box, be aware that you can then
no longer bind it to a field in a table or query, since a field can only
contain a single value.
 
G

Gary Miller

A listbox has a MultiSelect property which can be turned on
to do this. The real problem is getting the multiple choices
into a format to use easily.

Gary Miller
Sisters, OR
 
D

DanK

What are you doing with the selected data? Putting it
into a field as a string? Populating many fields based on
the selections? How many selections could the operator
make at most?

One possibiity is to assign controls on the form to the
selections made.

I only have 97 here so I can't play with the
multiselection part of it, but try playing around with
something like this:

Create 3 text boxes named 1, 2, and 3.
Create a combo box named: Name

OnUpdate of the Combo Box, enter:

If IsNull(Me![1]) Then
Me![1] = Me![Name]
End
End If

If IsNull(Me![2]) Then
Me![2] = Me![Name]
End
End If

If IsNull(Me![3]) Then
Me![3] = Me![Name]
End If

Cut this code and paste it.
Your selections are entered into the text boxes and you
can use them from there. Make the Text boxes invisible
after you get it working right.
 
A

Accessquestion

Thank you all for your suggestions. ;-)
-----Original Message-----
You can't for a combo box.

If you set MultiSelect property for a list box, be aware that you can then
no longer bind it to a field in a table or query, since a field can only
contain a single value.

--
Doug Steele, Microsoft Access MVP

(No private e-mails, please)






.
 

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