Here is the solution that seems to work, thanks XLD

Function SUMELIG(ByVal rngElig As Range, rngPercentage As Range)
SUMELIG = Application.Evaluate("SUM(If(ISERROR(" & rngElig.Address & " * " & rngPercentage.Address & "),0, " & rngElig.Address & "))")
End Function