- ©«¤l
- 406
- ¥DÃD
- 8
- ºëµØ
- 0
- ¿n¤À
- 453
- ÂI¦W
- 0
- §@·~¨t²Î
- WINDOWS 7
- ³nÅ骩¥»
- 2007
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2015-2-7
- ³Ì«áµn¿ý
- 2021-7-31
|
¦^´_ 10# b9208
À|¸Õ©ó¤u§@ªí2¦P®É¿é¥X¤J¤f¤Î¥X¤f²Îpªí¡Aµ{¦¡°õ¦æ¿ù»~
¦]¬°¤u§@ªí Outq ªºªí®æ¥ª¤WÁÙ¬O[B6] ¸ò¤u§@ªí2 ¤J¤fªí®æ¤@P
¦ý¬O¤u§@ªí2 ¥X¤fªí®æ¥ª¤WÅܦ¨ [P6] ¡A·Ç¤jªºµ{¦¡n¦Aקï¦ì¸m¤~¯à¥¿±`°õ¦æ
¤£¹L¥X¤f¤J¤fµ{¦¡ÅÞ¿è¤@¼Ë¡A¥u¦³§ìªº¦ì¸m»P¿é¥Xªº¦ì¸m¤£¦P¡A§Úı±o¨S¥²n§ï2¬qµ{¦¡
¥X¤f¡B¤J¤f¥i¥H¦X¨Ö¼g¡A§Ú¤]¦Û¤v¼g¤F¤@¬q¡A¨Ã¥[¤j¼u©Ê
N1~N4, S1~S5 ¶¶§ÇÀH«Kµ¹¤]¨SÃö«Y¡A³£¥i¥H§äªº¨ì¹ïÀ³¡A¥i¥H°Ñ¦Ò¬Ý¬Ý
µ{¦¡¦p¤U
Sub ²Îp¤J¤f()
[B6].CurrentRegion.Offset(2).Clear
²Îp [B6], 8
End Sub
Sub ²Îp¥X¤f()
[P6].CurrentRegion.Offset(2).Clear
²Îp [P6], 9
End Sub
Sub ²Îp(ByVal cel0 As Range, Ci As Long)
Dim D, Arr, Brr, T$, K1$, K2$, Key, R&, Ro&, Co&, Rg As Range
Set D = CreateObject("Scripting.Dictionary")
Arr = [¸ê®Æ!A4].CurrentRegion
For R = 2 To UBound(Arr)
K1 = Arr(R, 2): K2 = Arr(R, Ci)
If K1 <> T Then Ro = Ro + 1: D(K1) = Ro: T = K1
If K2 <> "" Then Key = K1 & "-" & K2: D(Key) = D(Key) + 1
Next
ReDim Brr(1 To Ro, 1 To 11)
For Each Key In D.keys
If InStr(Key, "-") = 0 Then Brr(D(Key), 1) = Key: GoTo ¤UÓKey
Ro = D(Split(Key, "-")(0))
Set Rg = cel0.Resize(, 10).Find(Split(Key, "-")(1), , , xlWhole)
If Not Rg Is Nothing Then
Co = Rg.Column - cel0.Column + 1
Brr(Ro, Co) = D(Key): Brr(Ro, 11) = Brr(Ro, 11) + D(Key)
End If
¤UÓKey: Next
With cel0(2).Resize(Ro, 11)
.Value = Brr: .Borders.LineStyle = 1
.VerticalAlignment = xlBottom
.HorizontalAlignment = xlCenter
End With
End Sub
Àɮצp¤U
W2-0822.rar (62.23 KB)
|
|