I would strongly suggest you store a ranking of sorts on the Paste sheet.
Given you're using XL2007 you can make use of the SUMIFS & COUNTIFS functions in pref. to Arrays given they are significantly more efficient.
Paste Sheet
L1: Agg. Score
L2: =SUMIFS($J$2:$J$1000,$A$2:$A$1000,$A2,$D$2:$D$1000,$D2,$E$2:$E$1000,$E2)
copied down
M1: Agg. Rank Key
M2: =COUNTIFS($A$2:$A$1000,$A2,$E$2:$E$1000,$E2,$L$2:$L$1000,">"&$L2)
copied down
With the above in place you can then collate your info on 'By Wm' sheet such that:
C146: =SUMIFS(Paste!$J$2:$J$1000,Paste!$A$2:$A$1000,$C$1,Paste!$G$2:$G$1000,$B146,Paste!$M$2:$M$1000,0)
copied down
by my reckoning the results should be 800, 800, 600, 10 rather than 630,550,800,9 ... your prior Array would only ever return the results for the first first test that met requirements (ie name & code) the scores themselves were never used as any basis for selection (ie MAX was never being accounted for).
The use of SUMIFS will be more efficient than the Array and also removes need for error handler (0 will be result should a combination not exist).
Bookmarks