Populating listbox with only one data
This is the event handler for AddButton upon click:
Private Sub AddButton_Click()
If ListBox1.ListIndex = -1 Then Exit Sub
For i = 0 to ListBox2.ListCount - 1
If ListBox1.Value = ListBox2.List(i) Then
Exit Sub
End If
Next i
ListBox2.AddItem ListBox1.Value
End Sub
" wrote:
I have to listbox controls. This form allows you to move data from one
listbox to the other
ListBox ADDBUTTON - Listbox2
If you can imagine the above when you hit the ADDBUTTON it should move
one of the rows from the left listbox to the right one. I just want
one piece of data to move over . Is there a parameter to do this?
|