Re:Remplir des listbox suite à un combobox
Salut Luc, adaptes ce code a ton fichier
WS etant le nom de ta feuille ou tu veux recuperer les données
Private Sub ComboBox1_Click()
If Me.ComboBox1.ListIndex = -1 Then Exit Sub 'ON sort si pas de sélection
TextBox1 = WS.Range('B' & Me.ComboBox1.ListIndex + 2) 'On alimente les données correspondant à la ligne
TextBox2.Value = WS.Range('c' & Me.ComboBox1.ListIndex + 2) 'On alimente les données correspondant à la ligne
TextBox3.Value = WS.Range('d' & Me.ComboBox1.ListIndex + 2)
TextBox4.Value = WS.Range('e' & Me.ComboBox1.ListIndex + 2)
TextBox5.Value = WS.Range('f' & Me.ComboBox1.ListIndex + 2)
With Me
End With
End Sub
@micalement
__________________
GEX 1403
|