AW: Listbox mit 2 Spalten aus untersch. Tabellenblätte
21.08.2017 21:09:49
Crazy
Hallo
eine Möglichkeit
Private Sub UserForm_Initialize()
Dim lngAnzahl As Long
Dim lngZeile As Long
ListBox1.ColumnCount = 2
ListBox1.ColumnWidths = "75;75"
ListBox1.Clear
With Sheets("Tabelle1")
For lngZeile = 7 To 100
ListBox1.AddItem .Cells(lngZeile, 2).Value
lngAnzahl = ListBox1.ListCount
ListBox1.List(lngAnzahl - 1, 1) = .Cells(lngZeile, 3).Value
Next lngZeile
End With
With Sheets("Tabelle2")
For lngZeile = 7 To 100
ListBox1.AddItem .Cells(lngZeile, 2).Value
lngAnzahl = ListBox1.ListCount
ListBox1.List(lngAnzahl - 1, 1) = .Cells(lngZeile, 3).Value
Next lngZeile
End With
End Sub
MfG Tom