by Steven Bailey (10 Submissions)
Category: Custom Controls/Forms/Menus
Compatability: Visual Basic 5.0
Difficulty: Unknown Difficulty
Originally Published: Sun 23rd April 2000
Date Added: Mon 8th February 2021
Rating: (1 Votes)
Ever wanted to use those tickboxes that are used by list boxes, well this code will let you do that, this code gets the items that you have
'please obay these instructions:
'
' 1. Remember to keep the following code in a command button
' 2. Replace "list1" and "list2" with the appropriate controls
' 3. Make sure that the first list is ither set with "multiselect"
' or the "checkbox" style.
Private Sub Command1_Click
Dim i As Integer
For i = 0 To List1.ListCount - 1
If List1.Selected(i) = True Then
List2.AddItem List1.List(i)
End If
Next i
End Sub
No comments have been posted about Ever wanted to use those tickboxes that are used by list boxes, well this code will let you do that. Why not be the first to post a comment about Ever wanted to use those tickboxes that are used by list boxes, well this code will let you do that.