Excuse me
I want to ask How To Transfer MultipleSelect Item In Listbox to another Listbox ?
Excuse me
I want to ask How To Transfer MultipleSelect Item In Listbox to another Listbox ?
Do you want the 'transfer' to occur immediately when selected? Use Click event of the multi-select listbox with AddItem method to add rows to the second listbox.
Why do you want to do this?
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
I want to try transfer item in the listbox to another listbox.
I succeed to transfer selected item, but I can't transfer multipleselect item.
Help me please.
You have to loop through the listbox selected items.
Review
http://allenbrowne.com/ser-50.html
http://office.microsoft.com/en-us/ou...080805489.aspx.
Your adaptation would be something like:This thread http://www.vb6.us/tutorials/indepth-...stbox-tutorial has a lot of info about working with listboxes. Your issue is discussed about quarter of the way down.Code:With Me.lstBox1 For Each varItem In .ItemsSelected If Not IsNull(varItem) Then Me.lstBox2.AddItem(varItem) 'I am not sure about this syntax End If Next End With
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
sorry, Can u explain this scriptYou have to loop through the listbox selected items.
Review
http://allenbrowne.com/ser-50.html
http://office.microsoft.com/en-us/ou...080805489.aspx.
Your adaptation would be something like:This thread http://www.vb6.us/tutorials/indepth-...stbox-tutorial has a lot of info about working with listboxes. Your issue is discussed about quarter of the way down.Code:With Me.lstBox1 For Each varItem In .ItemsSelected If Not IsNull(varItem) Then Me.lstBox2.AddItem(varItem) 'I am not sure about this syntax End If Next End With
Why that's script not work, when I try it.Code:Private Sub cmdMoveToLeft_Click() Dim i As Integer If List2.ListIndex = -1 Then Exit Sub For i = List2.ListCount - 1 To 0 Step -1 If List2.Selected(i) = True Then List1.AddItem List2.List(i) List2.RemoveItem i End If Next i End Sub
http://www.vbexplorer.com/VBExplorer...0/june2000.asp
Don't know, what happens - error message, wrong results, nothing? Where did you put the code?
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
I don't understand. The error is 'error'? Need more info.
I have never set up listboxes like this.
Can provide the file for analysis. Follow instructions at bottom of my post.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.