Yes - the colour is done manually - I've had a quick play in VB with this UDF
Function SumByColour(CellColour As Range, SumRange As Range)
Dim cell As Range
Dim SumColour As Double
Dim MySum
Application.Volatile
'If CellColour.Cells > 1 Then Exit Function
SumColour = CellColour.Interior.ColorIndex
For Each cell In SumRange
If cell.Interior.ColorIndex = SumColour Then
MySum = MySum + cell.Offset(0, -2)
End If
Next cell
SumByColour = MySum
End Function
found here:-
http://www.mrexcel.com/archive2/7400/8232.htm
but couldn't get it to work