list box Multi Select propery

J

Jake

Hi,
I have a user who wants to make multiple selections in a list box and i want
to store them in a table. If I set the Multi Select property to Simple it's
possible to make the selection, but they can't be stored in the underlying
table unless the Multi Select property is set to No. Is there a way to do
multiple selections and have them stored in a table from a list box or do
you need to use an option group?
Thank in advance for any help,
Jake
 
D

Douglas J. Steele

An option group won't help: it can only store one value.

Realistically, trying to store more than one value in a single field is a
violation of database normalization principles. Therefore, it's not
supported in Access. If it's critical to you, you can make your list box
unbound, and add logic in its AfterUpdate event to concatenate the values
and update the field in your table.
 
D

Dirk Goldgar

Douglas J. Steele said:
An option group won't help: it can only store one value.

Realistically, trying to store more than one value in a single field
is a violation of database normalization principles. Therefore, it's
not supported in Access. If it's critical to you, you can make your
list box unbound, and add logic in its AfterUpdate event to
concatenate the values and update the field in your table.

Or use the code to append each selection as a separate record in a
different, related table. That would preserve the relational integrity,
while still allowing the use of a list box, at the expense of additional
programming overhead. Code to do that has been posted in these
newsgroups, by me and by others, many times.
 
Top