multiple selection fx

  • Thread starter Thread starter Fred Loh
  • Start date Start date
F

Fred Loh

i would like to allow user to be able to select one or more (multiple) items
from a list of items. then, after the selection has been made and the
record saved, when the record is retrieved, the items that were selected will
be highlighted in the list as selected items. how can this be implemented in
Access (forms, tables, etc.)? how can the selections be saved? it was done in
another software. i am not sure if this can be achieved in Access.

thanks for your help
 
The only multiple select form control in Access is a list box. The default
is single select, but can be changed to multiple simple, or multiple
advanced. To save previous settings, you would need to loop through the list
box's ItemsSelected collection and update a field in the underlying table to
indicate the item was selected. When you load the form, you would need to
loop through the collection to show those marked in the table as selected.
 
You have to write some code to loop through the listbox ItemsSelected
collection and save the selections to a table. Then when the listbox is
redisplayed, you loop thru the table records and set the Selected property
for each listbox item that was previously selected.
It sounds harder than it is.

-Dorian
 
thanks Dave and Dorian.

it works! only thing is that i am saving the index of the selected items
together in one field. e.g. 1;3;7. (i think having one field for each item is
not efficient.). the down side to this is that i cannot do a search or query
 
Back
Top