Change Multiselect List box from multi to single select

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi there,

Using VBA, i am trying to change a list box from a multi-select list box to
a single select list box, but I am not having much luck. I tried this line,
but it throws an error, any ideas on how i can do this?

me.lstAccreditation.Multiselect = 2

Essentially i want to reuse a form to run different reports and i need to,
in one instance allow the user to select multiple criteria, where in others
only select one value.
 
The multiselect property can only be set in design view of the form. I wrote
code once the unselected all but the last item of a multi-select list box.
You might need to do the same or possibly use two list boxes and make one
visible at a time.
 
Back
Top