aynı anda listbox ve listview görüntüsü

Katılım
9 Ocak 2008
Mesajlar
133
Excel Vers. ve Dili
office xp
Sheets(ComboBox1.Text).Select
TextBox8.Text = ""

For i = 1 To 7
Controls("Label" & i + 1) = Cells(1, i).Value
Next i
If Sheets(ComboBox1.Text).Cells(65536, 1).End(xlUp).Row > 1 Then
With ListBox1
.ColumnCount = 7
.ColumnWidths = "50;50;50;50;50;50;120"
.List = Sheets(ComboBox1.Text).Range("A2:g" & Sheets(ComboBox1.Text).Cells(65536, 1).End(xlUp).Row).Value
End With

If Sheets(ComboBox1.Text).Cells(65536, 1).End(xlUp).Row > 1 Then
With ListView1
liste1 = Me.ListView1.ListItems.Add(, , S1.Cells(i, "A").Value)
liste1.SubItems(1) = S1.Cells(i, "B").Value
liste1.SubItems(2) = S1.Cells(i, "C").Value

End With
Else
ListBox1.Clear
TextBox1 = ""
TextBox2 = ""
TextBox3 = ""
TextBox4 = ""
TextBox5 = ""
TextBox6 = ""
TextBox7 = ""
End If
End If
End Sub

ben userforma yeni listview ekledim yapmak istediğim listbox 1 deki görüntülerin aynı zamanda listviewdede görüntülenmesi bunun için
eklemem gereken makroyu yukardakine ekleyebilirmisiniz
birde TextBox1 = ""
TextBox2 = ""
TextBox3 = ""
TextBox4 = ""
TextBox5 = ""
TextBox6 = ""
TextBox7 = "" şeklinde yazılanı kısaltma yapmak şansımız varmı
 
Son düzenleme:
Katılım
30 Kasım 2007
Mesajlar
22
Excel Vers. ve Dili
2003,2007 ve Türkçe
birde TextBox1 = ""
TextBox2 = ""
TextBox3 = ""
TextBox4 = ""
TextBox5 = ""
TextBox6 = ""
TextBox7 = "" şeklinde yazılanı kısaltma yapmak şansımız varmı
Kod:
for kodgentr=1 to 7
 Controls("Textbox" & kodgentr).value=empty
next kodgentr
Yukarıdaki bölüm işinizi görür.
 
Üst