I receive runtime error 13: Type Mismatch with the following code:

For i = 5000 To 4 Step -1
Range(Cells(i, 10)).FormulaArray = WorksheetFunction.max(Range(Cells(3, 3), Cells(5000, 3)) = Cells(i, 3)) * Range(Cells(3, 21), Cells(5000, 21))
Next
Any help on this is much appreciated.

Tariq