Option Explicit
Private Sub UserForm_Initialize()
Me.ListBox1.List = Range("Noms").Resize(, 2).Value
End Sub
Private Sub TextBox1_Change()
Dim i As String
Dim c As Variant
Me.ListBox1.Clear
i = 0
For Each c In Range(Sheets("Base gestion MDR").[F9], Sheets("Base gestion MDR").[F65000].End(xlUp))
If UCase(c) Like UCase(Me.TextBox1) & "*" Then
Me.ListBox1.AddItem
Me.ListBox1.List(i, 0) = c & " " & c.Offset(0, 1)
i = i + 1
End If
Next c
Me.ListBox1.ListIndex = 0
End Sub
Sub ListBox1_Click()
Dim ligne As Integer
ligne = Me.ListBox1.ListIndex + 9
Me.TextBox2 = Sheets("Base gestion MDR").Cells(ligne, 6)
Me.TextBox3 = Sheets("Base gestion MDR").Cells(ligne, 7)
End Sub