- ©«¤l
- 1446
- ¥DÃD
- 40
- ºëµØ
- 0
- ¿n¤À
- 1470
- ÂI¦W
- 0
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Excel 2010 & 2016
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2020-7-15
- ³Ì«áµn¿ý
- 2024-10-21
|
ÁÂÁ½׾Â,ÁÂÁ¦U¦ì«e½ú
«á¾ÇÂǦ¹©«½m²ß°}¦C»P¦r¨å,¾Ç²ß¤è®×¦p¤U
Option Explicit
Sub TEST_1()
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Dim Brr, Crr(1 To 1000, 1 To 1), A, Z, Q, i&, R&, T$
Set Z = CreateObject("Scripting.Dictionary")
For Each Q In Worksheets
If Q.Name <> "¤u§@ªí1" Then Q.Delete
Next
Brr = Range([¤u§@ªí1!A1], [¤u§@ªí1!A65536].End(xlUp)(2))
For i = 1 To UBound(Brr) - 1
If Brr(i + 1, 1) <> "¬¡°Ê" Then GoTo i01
T = Application.Text(Brr(i, 1), "[DBNum1]m¤ë")
A = Z(T): R = Z(T & "/r")
If Not IsArray(A) Then
A = Crr
A(1, 1) = T
A(2, 1) = Brr(i + 1, 1)
A(3, 1) = Brr(i + 2, 1)
Z(T) = 1: Z(T & "/r") = 3: i = i + 2: Z(T) = A: GoTo i01
End If
R = R + 1
A(R, 1) = Brr(i + 2, 1)
Z(T & "/r") = R: Z(T) = A
i01: Next
For Each Q In Z.KEYS
If Not IsArray(Z(Q)) Then GoTo z01
With Worksheets.Add(after:=Worksheets(Sheets.Count))
.Name = Q
.[A1].Resize(Z(Q & "/r"), 1) = Z(Q)
End With
z01: Next
Application.Goto [¤u§@ªí1!A1]
Set Z = Nothing: Erase Brr, A, Crr
End Sub
¾Ç²ß«ÂI:
1.¦r¨å ITEM¬O¤Gºû°}¦C
2.¤@¦¸©Ê¼g¤J¤u§@ªí¤¤ |
|