Function scr(champ As Range, couleurFond As Range)
Application.Volatile
Dim c, temp
temp = 0
x = ActiveCell.Interior.ColorIndex
For Each c In champ
If c.Interior.ColorIndex = couleurFond.Interior.ColorIndex Then
If IsNumeric(c.Value) Then temp = temp + c.Value
If c.Interior.ColorIndex = x Then GoTo prochain
End If
Next c
prochain:
scr = temp
End Function