TextBox1.SelStart = Len(TextBox1.Text)
TextBox1.SelText = vbCrLf & "coucou"
Private derlig As Long, premlig As Integer
Private Sub CommandButton2_Click() 'Quitter
Unload Me
End Sub
Private Sub ComboBox1_Change()
TextBox1.ControlSource = "B" & ComboBox1.List(ComboBox1.ListIndex) + premlig - 1
TextBox2.ControlSource = "C" & ComboBox1.List(ComboBox1.ListIndex) + premlig - 1
End Sub
Private Sub CommandButton1_Click()
For i = 1 To 18
ActiveSheet.Range(Chr(67 + i) & ComboBox1.ListIndex + premlig) = Controls("CheckBox" & i).Value
Next
End Sub
Private Sub UserForm_Initialize()
derlig = Range("A" & Rows.Count).End(xlUp).Row
premlig = 6 ' le numéro de ta 1ère ligne de données
ComboBox1.RowSource = "A" & premlig & ":A" & derlig
End Sub