T
Tim Coddington
Ok. Figured out how to load a list box
from an Excel range, like so ...
Private Sub UserForm_Initialize()
ListBox1.ColumnCount = 4
ListBox1.RowSource = "A2
" & Cells(1, 1).End(xlDown).Row
End Sub
Sample of spreadsheet values follows:
Name, First
Name, Last
Class
Address
Amber
Boger
2
[email protected]
Shane
Bobber
1
[email protected]
Sean
Cantral
1
[email protected]
Bobby
Smith
3
[email protected]
Lucy
Johnson
1
[email protected]
Linn
Cenad
2
[email protected]
Now I need to load ListBox1 from the same range, but only data
from a certain class, say 2. The list box would pick up Amber and
Linn, but not Sean (because he is class 1). Is there a way to do that?
from an Excel range, like so ...
Private Sub UserForm_Initialize()
ListBox1.ColumnCount = 4
ListBox1.RowSource = "A2
End Sub
Sample of spreadsheet values follows:
Name, First
Name, Last
Class
Address
Amber
Boger
2
[email protected]
Shane
Bobber
1
[email protected]
Sean
Cantral
1
[email protected]
Bobby
Smith
3
[email protected]
Lucy
Johnson
1
[email protected]
Linn
Cenad
2
[email protected]
Now I need to load ListBox1 from the same range, but only data
from a certain class, say 2. The list box would pick up Amber and
Linn, but not Sean (because he is class 1). Is there a way to do that?