re,
à tester,
ps/ je n'ai pas modifier le reste du code car je ne sais pas ce qu'il doit faire,
Private Sub Worksheet_Change(ByVal Target As Range)
Dim RA As Variant
If Target.Count > 1 Then Exit Sub
If Target.Column = 10 Then
If Target = "" Then Range("K" & Target.Row & ":M" & Target.Row).ClearContents
Else
ActiveSheet.Unprotect
If Target = 0 Then
Cells(Target.Row, 11).Select
Cells(Target.Row, 12).ClearContents
Do
RA = InputBox("Saisissez un nombre RA")
If Not Val(RA) > 0 Then MsgBox "Il faut saisir une valeur numérique"
Loop Until Val(RA) > 0
Cells(Target.Row, 11) = RA
Cells(Target.Row, 12).Locked = True
ActiveSheet.Protect
End If
If Target = 1 Then
Cells(Target.Row, 12).Select
Cells(Target.Row, 11).ClearContents
Do
RC = InputBox("Saisissez un nombre RC")
If Not Val(RC) > 0 Then MsgBox "Il faut saisir une valeur numérique"
Loop Until Val(RC) > 0
Cells(Target.Row, 12) = RC
Cells(Target.Row, 11).Locked = True
ActiveSheet.Protect
End If
If Target <> 0 And Target <> 1 Then
Cells(Target.Row, 11).Select
Do
RA = InputBox("Saisissez un nombre RA")
If Not Val(RA) > 0 Then MsgBox "Il faut saisir une valeur numérique"
Loop Until Val(RA) >= 0
Cells(Target.Row, 11) = RA
Do
RC = InputBox("Saisissez un nombre RC")
If Not Val(RC) > 0 Then MsgBox "Il faut saisir une valeur numérique"
Loop Until Val(RC) >= 0
Cells(Target.Row, 12) = RC
End If
End If
End Sub