Merci de me dire ou vous avez fait les modifications.
J'ai créé une variable ln qui repère le numéro de la ligne où se trouve la valeur du combobox dans la feuille "Traces2" :
Private Sub Enregistrer_Click()
Dim Message As String, VarReponse As String
Label1.ForeColor = RGB(0, 0, 0)
With Sheets("Traces2")
For ln = 3 To .Range("A" & Rows.Count).End(xlUp).Row
If .Range("B" & ln) = ComboBox1 Then
Exit For
End If
Next ln
End With
et, plus loin dans l a même macro, j'ai remplacé la variable lgn par ln dans ce que se rapporte à la feuille "Traces2"
Case 2 'modifier
If ComboBox1.ListIndex = -1 Then
MsgBox "Vous devez choisir un Nom.", 16
Label1.ForeColor = RGB(255, 0, 0)
Exit Sub
End If
Set Ws = Worksheets("Inscriptions2")
With Ws
Lgn = TrouveLigne(ComboBox1)
.Range("B" & Lgn) = TextBox1 * 1 'moyenne sérieux
.Range("C" & Lgn) = ComboBox7 * 1 'autre 1
.Range("D" & Lgn) = TextBox2 * 1 'moyenne autre 2
.Range("E" & Lgn) = TextBox3 * 1 'moyenne essai
.Range("F" & Lgn) = TextBox4.Value 'observation
End With
With Sheets("Traces2")
.Range("A" & ln) = Now
'.Range("B" & Lgn) = ComboBox1
For I = 2 To 6 'B à G
.Cells(ln, I + 1) = Val(Controls("ComboBox" & I))
Next I
.Range("H" & ln) = TextBox1 * 1 'moyenne sérieux
.Range("I" & ln) =
...
OK ?
Bye !