1.4k Aufrufe
Gefragt in Tabellenkalkulation von
Mahlzeit,

Ich habe eine Tabelle von A bis Z und möchte in einer Listbox die Spalten C, D und I anzeigen lassen.
Ist das möglich, wenn ja wie?

Danke

5 Antworten

0 Punkte
Beantwortet von hajo_zi Experte (9.1k Punkte)

Dim Loletzte As Long
Dim LoI As Long
Loletzte = IIf(IsEmpty(Cells(Rows.Count, 1)), Cells(Rows.Count, 1).End(xlUp).Row, Rows.Count)
For LoI = 1 To Loletzte
ListBox1.AddItem Cells(LoI, 3)
ListBox1.List(LoI - 1, 1) = Cells(LoI, 4)
ListBox1.List(LoI - 1, 2) = Cells(LoI, 4)
Next iCounter


Gruß Hajo
0 Punkte
Beantwortet von hajo_zi Experte (9.1k Punkte)
Next LoI
am Ende

Gruß Hajo
0 Punkte
Beantwortet von
Hallo Hajo,

leider klappt es bei mir nicht.:-(
ich hab das mal angepasst, da bei mir die zeile bei 16 anfängt.

Es wird nur die spalte C übertragen.

Dim Loletzte As Long
Dim LoI As Long
Loletzte = Range("C100").End(xlUp).Row
For LoI = 16 To Loletzte
Listbox1.AddItem Cells(LoI, 3)
Listbox1.List(LoI - 16, 1) = Cells(LoI, 4)
Listbox1.List(LoI - 16, 2) = Cells(LoI, 4)
Next LoI
0 Punkte
Beantwortet von hajo_zi Experte (9.1k Punkte)
das letzt Cells mus nicht 4 sondern 9 sein.
Ich sehe Deine datei nicht.
Ich baue keine Datei nach, die Zeit hat schon jemand investiert. Ein Link zur Datei wäre nicht schlecht.

Gruß Hajo
0 Punkte
Beantwortet von
Hallo Hajo,

besten Dank hat funktioniert.
...