Function SommeSiCouleur(Plage As Range, NumeroDeCouleur%) As Double
Application.ScreenUpdating = False
Application.Volatile True
Dim wCell As Range
For Each wCell In Plage
If wCell.Interior.ColorIndex = NumeroDeCouleur Then
SommeSiCouleur = SommeSiCouleur + wCell.Value
End If
Next
End Function