根据颜色求和
Function SumColor(i As Range, ary1 As Range)
Dim icell As Range
Application.Volatile
For Each icell In ary1
If icell.Interior.ColorIndex = i.Interior.ColorIndex Then
SumColor = Application.Sum(icell) + SumColor
End If
Next icell
End Function
页:
[1]