- ©«¤l
- 2834
- ¥DÃD
- 10
- ºëµØ
- 0
- ¿n¤À
- 2890
- ÂI¦W
- 0
- §@·~¨t²Î
- ¡e²¤¡f
- ³nÅ骩¥»
- ¡e²¤¡f
- ¾\ŪÅv
- 100
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¡e²¤¡f
- µù¥U®É¶¡
- 2013-5-13
- ³Ì«áµn¿ý
- 2024-11-25
|
¦^´_ 6# oak0723-1
- Sub TEST()
- Dim i&, R&, C&, Arr, Brr, xD, V, U
- Call Clear_All
- Arr = Range("A8:D" & Cells(Rows.Count, 1).End(xlUp).Row)
- Set xD = CreateObject("Scripting.Dictionary")
- For i = 1 To UBound(Arr): xD(Arr(i, 2)) = "": Next i
- U = xD.Count
- For i = 1 To U
- V = Application.Large(xD.keys, i)
- xD(V) = i * 8 - 7: [i6].Cells(1, xD(V)) = V
- Next i
- R = Cells(Rows.Count, "H").End(xlUp).Row - 10
- If R <= 0 Then Exit Sub
- Brr = [H11].Resize(R)
- For i = 1 To R: xD(Brr(i, 1)) = i: Next i
- ReDim Brr(1 To R, 1 To U * 8)
- For i = 1 To UBound(Arr)
- R = xD(Arr(i, 1)): C = xD(Arr(i, 2)): If R = 0 Or C = 0 Then GoTo 101
- V = Arr(i, 3)
- If V >= [I9] And V < [K9] Then Brr(R, C + 0) = Brr(R, C + 0) + V: Brr(R, C + 1) = Brr(R, C + 1) + 1
- If V >= [M9] And V < [O9] Then Brr(R, C + 4) = Brr(R, C + 4) + V: Brr(R, C + 5) = Brr(R, C + 5) + 1
- V = Arr(i, 4)
- If V >= [I9] And V < [K9] Then Brr(R, C + 2) = Brr(R, C + 2) + V: Brr(R, C + 3) = Brr(R, C + 3) + 1
- If V >= [M9] And V < [O9] Then Brr(R, C + 6) = Brr(R, C + 6) + V: Brr(R, C + 7) = Brr(R, C + 7) + 1
- 101: Next i
- [i11].Resize(UBound(Brr), UBound(Brr, 2)) = Brr
- End Sub
½Æ»s¥N½X
060318-¬y¤ô±b&¤ÀÃþ±b_v1.rar (15.54 KB)
|
|