Hi

This works fine.

=SUMPRODUCT(--(Sheet1!$A$1:$AP$1=Sheet2!$A3)*(Sheet1!C2:C101=1))

But when I extend the range in the 2nd condition to the following, it returns an #NA

=SUMPRODUCT(--(Sheet1!$A$1:$AP$1=Sheet2!$A3)*(Sheet1!C2:AP101=1))

Is there a formula that can do the latter?

Thanks