Clear list box selection

  • Thread starter Thread starter Opal
  • Start date Start date
O

Opal

In Access 2003, how can I clear
the selection from a list box in an
unbound form?

I tried:

LstTM.ListIndex = -1

but I get an error telling me:

'You've used the ListIndex property incorrectly"
 
It depends on whether you've got MultiSelect enabled (and what type of
MultiSelect if you do), but try

LstTM = Null
 
Hi Doug,

I set the box to "Simple" multi-select

and

LstTM = Null

does not work

:-(
 
In that case, try:

LstTM.RowSource = LstTM.RowSource


LstTM = Null will work if MultiSelect is None or Extended.

LstTM.RowSource = LstTM.RowSource will work if MultiSelect is Simple or
Extended.
 
Thank you Doug, I will give it a try on Monday
when I get back into work.
 

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

Back
Top