- Create a listbox
- Create a command button
- Double click the Command button and past the code
Code:
Dim I As Integer
For I = 0 To List1.ListCount - 1
'Code to do with each item in that list box here
Next I
Use of that code:
In between For and Next I insert the code you want to be used on each item from that list box.
Example:
Code:
Dim I As Integer
For I = 0 To List1.ListCount - 1
'Code to do with each item in that list box here
Text1.Text = List1.List(I)
Next I
Basically all that would do, is change the text of text1.text to the value of the current listbox item.
Any questions? Feel free to ask.