February 2, 2013
Hi Every one !
Possible to update formula based on color identification.
Moderators
January 31, 2022
You need a User Defined Function for this in VBA. I found a piece of code in a collection of old files that works provided that you color the cell with the total the same as the colors in the sum range.
The code is as follows:
Function SumColor(rngCol As Range)
Application.Volatile
Dim C As Long Dim Total As Variant
C = Application.ThisCell.Interior.Color
Total = 0
For Each
Cell In rngCol
If Cell.Interior.Color = C Then
Total = Total + Cell.Value
End If
Next
SumColor = Total
End Function
See attached file using this function.
Answers Post
October 5, 2010
Hi Saliha,
Check out this post, it may be useful for you
Count, Sum and Average Colored Cells
Regards
Phil
1 Guest(s)