Dim a, b, n As Byte 'mémorise les variables
Private Sub ListBox1_DblClick(ByVal Cancel As MSForms.ReturnBoolean)
a = Array("TextBox1", "TextBox3", "TextBox5", "TextBox7")
b = Array("TextBox2", "TextBox4", "TextBox6", "TextBox8")
With ListBox1
Me(a(n)) = .Column(0)
Me(b(n)) = .Column(1)
End With
n = IIf(n = 3, 0, n + 1)
End Sub
Private Sub ListBox1_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
If Button <> 2 Then Exit Sub 'Button = 2 => clic droit
ListBox1.ListIndex = -1 'désélectionne
If Not IsArray(a) Then Exit Sub
n = IIf(n = 0, 3, n - 1)
Me(a(n)) = ""
Me(b(n)) = ""
End Sub