Private Sub Worksheet_Change(ByVal Target As Range)
Dim Cell As Range
For Each Cell In Target
' Saisie en colonne C
If Cell.Column = 3 Then
If Cell.Offset(0, 1).Value <= 2 And Cell.Value = "Rayon" Then
Cell.Offset(0, 2).FormulaR1C1 = "=ROUNDUP(RC[-1]*0.25,1)"
Else
Cell.Offset(0, 2).FormulaR1C1 = "=Ci(RC[-1])"
End If
' Saisie en colonne E
ElseIf Cell.Column = 5 Then
If Cell.Value <= 2 And Cell.Offset(0, -2).Value = "Rayon" Then
Cell.Offset(0, 1).FormulaR1C1 = "=ROUNDUP(RC[-1]*0.25,1)"
Else
Cell.Offset(0, 1).FormulaR1C1 = "=Ci(RC[-1])"
End If
End If
Next Cell
End Sub