Storing Multiple Selections from a list box

L

LesG

I am TERRIBLE at loops etc and need some help please? I have a listbox
control with the following attributes:
Name: Flavours
Control Source: Flavours
Row Source Type = table
Row Source: SELECT Brands.BrandID, Brands.Brand FROM Brands;
Multi Select: Extended

The control source has a list of flavours such as Coca-Cola, Fanta, Sprite
etc. I want to be able to select multiple selections and store the multiple
selections in the control & underlying table... How would I could this
 
A

Allen Browne

Use a continuous subform instead of a list box.
Then you don't need any code at all.

Underlying your question is the more fundamental issue of the tables you
need to store this data in. The idea of having a related table so you can
associate multiple brands with one entity is crucially important. If that's
new, take a look at an example such as this:
Don't use Yes/No fields to store preferences
at:
http://allenbrowne.com/casu-23.html
 
L

LesG

Hi Allen... Thanks for your response (all the way from Aus). I am probably
being a dumb South African but...

I am creating relational database... There are a number of tables, one of
them is a list of cooldrink brands / flavours. Another table is an order
table (called PDA) and the next table will be an order detail table.
The specific control I am working with is in the PDA table and is linked to
the Flavour table table with a one to many relationship (one "order" will use
many "flavours")... The underlying table (flavours) lists brands / flavours
of soft drinks. When the user selects one or more brands / flavours, the the
'PDA' table will store the selected values.

hope this clarifies my question?
 
L

LesG

Thanks for your help Allen.... I have solved my problem... too lazy to work
it out

Regards

Les
 

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