¦Û°Ê¡i§PŪ¦³¼Ð¥Ü«ü©w©³¦âªº¼Æ¦r¦¸¼Æ¡j&¡i¦¸¼Æ¥[Á`¡j&¡i¿é¥XÀɮסj¤§»yªk¡C
- ©«¤l
- 315
- ¥DÃD
- 51
- ºëµØ
- 0
- ¿n¤À
- 367
- ÂI¦W
- 0
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-9-29
- ³Ì«áµn¿ý
- 2021-10-12
|
¥»©«³Ì«á¥Ñ Airman ©ó 2019-5-4 23:01 ½s¿è
¦^´_ 13# Scott090
Scott090¤j¤j:±z¦n!
¤£¦n·N«ä¡A¨S¦³ª`·N¨ì±zµ{¦¡¼g¦b¼Ò²Õ1^^"
¦b°õ¦æÀɲK¥[Main
¤w¥i¥¿½T°õ¦æ¡C
°õ¦æ«á~µª®×¥¿½T~´ú¸Õ¦¨¥\~·P®¦^^
¯S§O·PÁ±zªº¤å¦rµù¸Ñ^^ |
|
|
|
|
|
|
- ©«¤l
- 315
- ¥DÃD
- 51
- ºëµØ
- 0
- ¿n¤À
- 367
- ÂI¦W
- 0
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-9-29
- ³Ì«áµn¿ý
- 2021-10-12
|
¦^´_ 13# Scott090
Scott090¤j¤j:±z¦n!
¤£¦n·N«ä¡A2Ó"²Îp"Àɬ°2007ª©µLªk¶}±Ò®Ö¹ïµª®×¡F
¥Dµ{¦¡ÀÉÂI°õ¦æÁä~¨S¦³¤ÏÀ³^^" |
|
|
|
|
|
|
- ©«¤l
- 315
- ¥DÃD
- 51
- ºëµØ
- 0
- ¿n¤À
- 367
- ÂI¦W
- 0
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-9-29
- ³Ì«áµn¿ý
- 2021-10-12
|
¦^´_ 12# ã´£³¡ªL
ã¤j:±z¦n!
´ú¸Õ¦¨¥\~·P®¦^^
±z»¡ªº¨S¦³¿ù~
' If R < 10 Then xB.Close 0: GoTo 101
§ï¬°
If R < 2 Then xB.Close 0: GoTo 101 '·Ó¼ÒÀÀÀ³¸Ó¥Î³o¤@¦æ
µª®×¤~¬O¥¿½Tªº¡CÁÂÁ±z^^ |
|
|
|
|
|
|
- ©«¤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-27
|
¥»©«³Ì«á¥Ñ ã´£³¡ªL ©ó 2019-5-4 19:00 ½s¿è
Private Sub CommandButton1_Click()
Dim BK As Workbook, F$, T$, xB As Workbook, xS As Worksheet
Dim xD, Arr(1 To 7, 1 To 49), Brr, R&, V, xR As Range
Set BK = ThisWorkbook
Set xD = CreateObject("Scripting.Dictionary")
Application.ScreenUpdating = False
Do
If F = "" Then F = Dir(BK.Path & "\*.xls") Else F = Dir()
If F = "" Then Exit Do
If Not F Like "¤µ¤éÁ`ªí(§¡È±Æ§Ç)-*_*-(####-##-##).xls" Then GoTo 101
T = Left(Right(F, 16), 12)
Brr = xD(T)
If Not IsArray(Brr) Then xD(T) = Arr: Brr = Arr
'-----------------------------------------------
Set xB = Workbooks.Open(BK.Path & "\" & F, ReadOnly:=True): Set xS = xB.Sheets(1)
R = xS.[A65536].End(xlUp).Row - 8
If R < 10 Then xB.Close 0: GoTo 101
'If R < 2 Then xB.Close 0: GoTo 101 '·Ó¼ÒÀÀÀ³¸Ó¥Î³o¤@¦æ
For Each xR In xS.Cells(R, 2).Resize(1, 49)
V = InStr("---8--37-38-4--45-39-40-", "-" & xR.Interior.ColorIndex & "-") / 3
If Val(xR) > 0 And V > 0 Then Brr(V, xR) = Brr(V, xR) + 1
Next
xD(T) = Brr: xB.Close 0
101: Loop
'----------------------------------------------------
If xD.Count = 0 Then Exit Sub
Application.DisplayAlerts = False
For Each V In xD.keys
F = "¤µ¤éÁ`ªí(§¡È±Æ§Ç)-" & V & "_²Îp.xls"
BK.Sheets("Sample").Copy
With ActiveWorkbook
.Sheets(1).[B2].Resize(7, 49).Value = xD(V & "")
.SaveAs Filename:=BK.Path & "\" & F, CreateBackup:=False
.Close 0
End With
Next
End Sub
»P¼ÒÀÀµ²ªG¤£¦P, ¶È¥H "Àx¦s®æ©³¦â" ¤Î "¼Æ¦r" ¬°§P§O,
¤µ¤éÁ`ªí(§¡È±Æ§Ç).rar (71.11 KB)
|
|
|
|
|
|
|
- ©«¤l
- 315
- ¥DÃD
- 51
- ºëµØ
- 0
- ¿n¤À
- 367
- ÂI¦W
- 0
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-9-29
- ³Ì«áµn¿ý
- 2021-10-12
|
¥»©«³Ì«á¥Ñ Airman ©ó 2019-5-4 14:46 ½s¿è
¦^´_ 10# Scott090
Scott090¤j¤j:±z¦n!
1. ÀÉ®×¥H ¤é´Á§Ç °µ¤ÀÃþ¡F »P X-Y µLÃö ==> OK! 8#ªº¸É¥R»¡©ú~½Ð"©¿²¤"§Y¥i¡C
2. ¦P¤@¤ÀÃþ¤º¨C¤@ÓÀɮ׳£°µ¬Û¦Pªº²Îp³W«h¡A
²Îp³W«h¡G
..........
..........
²Îp³W«h¡G¤£¹ï!
³W«h«ÂI¾ã²z~ÂԽаѦÒ~
²Îp½d³ò¡G
1_Àɮפº¤u§@ªíªºCells([B65536].End(xlUp).Row) <10(§Y³Ì«á¦³¼Æ¦rªº¦C¼Æ¤p©ó²Ä10¦C)ªºÀɮײ¤¹L¤£p¡C
2_·j´M²Îpªº½d³ò±q²Ä2¦C(§Y²Ä¤@¦C¼ÐÃDªº¼Æ¦r¤£¦bpºâ½d³ò)¨ìCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)¡C
²Îp³W«h¡G
³æ¤@Ó(§Y¦³¼Ð¥Ü40¸¹©³¦â)¬O«ü¡JÀɮפºªº¤u§@ªí¤§
·íCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)¦³Åã¥Ü¼Æ¦r(§Y<>"")¡A
¦ýCells([B65536].End(xlUp).Row - 9, 2).Resize(1, 49)ªº¦PÄæ¨S¦³¼Æ¦r(§Y="")
©Î
·íCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)=²Ä2¦C®É¡A¬YÄ榳Åã¥Ü¼Æ¦r(§Y<>"")¡A
³s2Ó(§Y¦³¼Ð¥Ü39¸¹©³¦â)¬O«ü¡JÀɮפºªº¤u§@ªí¤§
·íCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)¦³Åã¥Ü¼Æ¦r(§Y<>"")¡A
¥BCells([B65536].End(xlUp).Row - 9, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¦ýCells([B65536].End(xlUp).Row - 10, 2).Resize(1, 49)ªº¦PÄæ¨S¦³¼Æ¦r(§Y="")
©Î
·íCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)=²Ä3¦C®É¡A¬YÄ榳Åã¥Ü¼Æ¦r(§Y<>"")¡A
¥BCells([B65536].End(xlUp).Row - 9, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
³s3Ó(§Y¦³¼Ð¥Ü45¸¹©³¦â)¬O«ü¡JÀɮפºªº¤u§@ªí¤§
·íCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)¦³Åã¥Ü¼Æ¦r(§Y<>"")¡A
¥BCells([B65536].End(xlUp).Row - 9, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¥BCells([B65536].End(xlUp).Row - 10, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¦ýCells([B65536].End(xlUp).Row - 11, 2).Resize(1, 49)ªº¦PÄæ¨S¦³¼Æ¦r(§Y="")
©Î
·íCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)=²Ä4¦C®É¡A¬YÄ榳Åã¥Ü¼Æ¦r(§Y<>"")¡A
¥BCells([B65536].End(xlUp).Row - 9, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¥BCells([B65536].End(xlUp).Row - 10, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¨ä¾l³s4Ó¡A....¡A³s6Ó¥H¦¹Ãþ±À¡C
³s7Ó(§Y¦³¼Ð¥Ü8¸¹©³¦â)¬O«ü¡JÀɮפºªº¤u§@ªí¤§
·íCells([B65536].End(xlUp).Row - 8, 2).Resize(1, 49)¦³Åã¥Ü¼Æ¦r(§Y<>"")¡A
¥BCells([B65536].End(xlUp).Row - 9, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¥BCells([B65536].End(xlUp).Row - 10, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¥BCells([B65536].End(xlUp).Row - 11, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¥BCells([B65536].End(xlUp).Row - 12, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¥BCells([B65536].End(xlUp).Row - 13, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"")
¥BCells([B65536].End(xlUp).Row - 14, 2).Resize(1, 49)ªº¦PÄæ¤]¦³¼Æ¦r(§Y<>"") |
|
|
|
|
|
|
- ©«¤l
- 315
- ¥DÃD
- 51
- ºëµØ
- 0
- ¿n¤À
- 367
- ÂI¦W
- 0
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2015-9-29
- ³Ì«áµn¿ý
- 2021-10-12
|
¥»©«³Ì«á¥Ñ Airman ©ó 2019-5-4 11:44 ½s¿è
¦^´_ 7# Scott090
Scott090¤j¤j:±z¦n!
¨«¦ì¦³ÂIÄY«~¥HÁ`¼Æp¡J¡i01~06¦@9Ó¡jÀ³¸Ó¨S¦³¿ù^^
¥t¥~~¬õ¦â¦rªº½s½X¡A¤p§Ì§@ӸɥR¡J
X_Y
X=¸¹½X±Æ§Ç=1~49(©Ò¥H¤@Ó¤é´Á§O¦³49ÓÀÉ®×)
Y=´Á¶Z=¦³_³s1¡F_³s2¡F... ¡F_³s10¡F_1¡F_2¡F.... ¡F_99¡F_100µ¥¤£©wªº½s½X¡A(©Ò¥H¤@Ó¤é´Á§O¦³49(§t)Ó¥H¤º(§Y·|¦³«½Æ)ªº´Á¶Z½s½X)¡C
¥H¤WÂԨѰѦÒ! ÁÂÁ±z^^ |
|
|
|
|
|
|