Hello everyone
I am stuck of the use of the SUMPRODUCT in VBA
I have this formula
=SUMPRODUCT((SH!$D$12:$D$22="Male")*(SH!$E$12:$E$22=1))
And I used variables for ranges :
rGender = SH!$D$12:$D$22
rGrade =SH!$E$12:$E$22

When I tried this line it failed
MsgBox Application.WorksheetFunction.SumProduct(rGender, strMale, rGrade, grade)
Any help please ....