Option Explicit Function CountByColor(CellColor As Range, SumRange As Range) Dim myCell As Range Dim iCol As Integer Dim myTotal iCol = CellColor.Interior.ColorIndex For Each myCell In SumRange If myCell.Interior.ColorIndex = iCol Then myTotal = myTotal + 1 End If Next myCell CountByColor = myTotal End Function
|Multi-user Excel not reflecting who actually has the file opened||10||30|
|Hiding column macro||10||28|
|excel cannot open the file because the file format or file extension is not valid||5||32|
|Help with Excel formula||6||38|
Join the community of 500,000 technology professionals and ask your questions.
Connect with top rated Experts
12 Experts available now in Live!