sub test ()
dim arr,brr(),x&,i&,d as object,str1$
set d=createojbedt("scripting.dictionary")
arr=range("A1:C"& range("A65536").end(xlup).row)
redim brr(1 to 3,1 to 1)
for x=1 to ubound(arr)
str1=arr(x,2) & "|" & arr(x,3)
if not d.exists(str1) then
i=i+1
d(str1)=i
redim preserve brr(1 to 3,1 to i)
brr(2,i)=arr(x,2)
brr(3,i)=arr(x,3)
end if
brr(1,d(str1))=brr(1,d(str1))+arr(x,1)
next x
range("E1").resize(ubound(brr,2),3)=application.transpose(brr)'妳要統計到哪就把前面的單元格地址改成妳要寫到的地方即可
end sub