Here's how I read your request.
UDF
Formula in Sheet2!B2
=CountName(Sheet1!$A$2:$C$40,B$1,$A2,3)
then copy right + down
Function CountName(rng As Range, myWeek, myName, myColorIndex As Long) As Long
Dim r As Range, x, e
Application.Volatile
myWeek = Val(Split(myWeek & " ")(1))
With rng
x = Filter(.Parent.Evaluate("transpose(if((" & .Columns(1).Address & "=" & myWeek & ")*(" & _
.Columns(2).Address & "=""" & myName & """)*(" & .Columns(3).Address & _
"<>""""),row(1:" & .Rows.Count & ")))"), False, 0)
If UBound(x) > -1 Then
For Each e In x
CountName = CountName + Abs(rng.Cells(e, 2).Font.ColorIndex <> myColorIndex)
Next
End If
End With
End Function
Bookmarks