Results 1 to 3 of 3
  1. #1
    2 Star Lounger
    Join Date
    Jul 2002
    Location
    North Dakota, USA
    Posts
    184
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Deselect Items in MultiSelect Listbox (Access 2000)

    I'd like to create a button on a form that will deselect everything I have selected in a multiselect listbox. What's the code for that? I've tried the following with errors.

    me.listbox.itemselected.count = 0
    me.listbox.selected = false

    Sarah

  2. #2
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Deselect Items in MultiSelect Listbox (Access 2000)

    This works.
    <pre> Dim vntItem As Variant

    For Each vntItem In Listbox.ItemsSelected
    Me!Listbox.Selected(vntItem) = False
    Next
    </pre>

    Regards
    John



  3. #3
    2 Star Lounger
    Join Date
    Jul 2002
    Location
    North Dakota, USA
    Posts
    184
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Deselect Items in MultiSelect Listbox (Access 2000)

    Thanks John.

    It worked great!

    Sarah

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •