multiselect list box for data entry

SusanC

Registered User.
Local time
Today, 15:56
Joined
Feb 18, 2004
Messages
66
Hi,
I am using Access XP.

I have a table for experiments - tblexp.
Each experiment can have one or more projects within it. So I have a drop down list of the various projects in a separate table - tblprojref with fields project no (projno) and project title (protitle).

When I am setting up a new experiment I am entering the information into a form. Along with other information that populates the underlying table, I would like to have a multiselect list box which allows me to pick the projects linked to the experiment. These would then either populate the same tblexp or another. I can only achieve this if I am only selecting one project from the list.

How can I get the several items selected into different fields and linked to the one experiment?
I am new to this and although have found various threads relating to this they include a lot of code which I don't understand. Is there a step by step easy way to achieve this?

hope I've explained it properly,
any help would be great,
thanks
Sue
 
You need to use VBA to get the info into seperate fields. You will have to loop through the ItemSelected Collection and retrieve the data. I don't think you would want to store each project in a different field but rather have one to many relation ship from the experiment and project table. One experiment can have many projects.
 
Last edited:
Hi,
i thought I would need a new table for the proj refs. Do you know where I can find the code as well as how to put it in?
thanks for all your help,
Sue
 

Users who are viewing this thread

Back
Top Bottom