Private Sub Worksheet_Change(ByVal Target As Range)
Dim d As Object, tablo, i&, x$, v#, n&
Set d = CreateObject("Scripting.Dictionary")
d.CompareMode = vbTextCompare 'la casse est ignorée
With [A1].CurrentRegion.Resize(, 4)
tablo = .Value 'matrice, plus rapide
For i = 2 To UBound(tablo)
x = tablo(i, 1) & Chr(1) & tablo(i, 2)
v = Val(Replace(tablo(i, 3), ",", "."))
If d.exists(x) Then
tablo(i, 4) = ""
n = d(x)
tablo(n, 4) = tablo(n, 4) + v
Else
d(x) = i 'mémorise la ligne
tablo(i, 4) = v
End If
Next
Application.EnableEvents = False 'désactive les évènements
.Columns(4) = Application.Index(tablo, , 4) 'restitution
Application.EnableEvents = True 'réactive les évènements
End With
End Sub