ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

[µo°Ý] ¦C¥X§ó¦hªº¹ïÀ³¸ê®Æ

¦^´_ 35# °a¤ªºµ

¥Ø«e´ú¸Õ

¦pªG³W®æ¬°ªÅ¥Õ(§Ñ°O¥´)¡A¨Ì·íªì©wªº±ø¥ó¨Ó¬Ý¡A¥u·|¦C¥X¨º¦Cªº¸ê®Æ¡A¦ý¬Ý°_¨Ó§A§â¸Ó¦C¦³¬Û¦P«~¦WªºÃöÁä¦r¥þ³¡§ä¥X¨Ó¤F¡C

TOP

¥»©«³Ì«á¥Ñ °a¤ªºµ ©ó 2020-8-24 22:41 ½s¿è

¦^´_ 34# qaqa3296
¨S¿ìªk¤F ·Q¤£¥X¨Ó ¤å¦rªº®æ¦¡¤Ó½ÆÂø¤F...  ¦pªG¬O¥Î asc ¤èªk ·|¼g±o§óªø....¥u¯à­É¥Î ­ã´£³¡ªL¤j¤j ÁÙ¦³ n7822123¤j¤j ­ÌªºÅÞ¿è...¤~¯à¿ì¨ì >"<
Public Sub ¼Ò½k¿z¿ï()

Application.ScreenUpdating = False
Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(255, 0, 0)
G = True
Sheets(3).Select
Sheets(3).Range(Cells(1, 1), Cells(1, 4).End(xlDown)).Clear
Sheets(2).Select

For K = 2 To Cells(2, 5).End(xlDown).Row
    X = Trim(Sheets(1).Cells(K, 3))
    If Sheets(1).Cells(K, 1) = "" Then Exit For
   
    For i = 2 To Cells(2, 3).End(xlDown).Row '¨Ì±ø¥ó¿z¿ï

        If X <> "" Then
        
            Sheets(2).Cells(2, 3).AutoFilter
            Cells(i, 1).AutoFilter Field:=3, Criteria1:="=*" & Mid(X, 1, 8) & "*", Operator:=xlOr, Criteria2:="=" & X & ""
            Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)

            Cells(i, 1).AutoFilter Field:=3, Criteria1:="=*" & Mid(X, 1, 5) & "*", Operator:=xlOr, Criteria2:="=" & X & ""
            Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            
            If X Like "####[-.]*" Or X Like "####[A-Z]*" Then
                Cells(i, 1).AutoFilter Field:=3, Criteria1:="=*" & Mid(X, 1, 4) & "*", Operator:=xlOr, Criteria2:="=" & X & ""
                Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            End If

            If ActiveSheet.AutoFilter.Range.SpecialCells(xlCellTypeVisible).Areas.Count = 1 Then
                Sheets(2).Cells(2, 3).AutoFilter
                Cells(i, 1).AutoFilter Field:=2, Criteria1:="=*" & X & "*", Operator:=xlOr, Criteria2:="=" & X & ""
                Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
               
                Cells(i, 1).AutoFilter Field:=2, Criteria1:=Sheets(1).Cells(K, 2)
                Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            End If
        End If
         
        If X = "" Then
            X = Trim(Sheets(1).Cells(K, 2))
            Cells(i, 1).AutoFilter Field:=2, Criteria1:="=*" & X & "*", Operator:=xlOr, Criteria2:=Sheets(1).Cells(K, 2)
            Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            If ActiveSheet.AutoFilter.Range.SpecialCells(xlCellTypeVisible).Areas.Count = 1 Then
                Sheets(2).Cells(2, 3).AutoFilter
                Cells(i, 1).AutoFilter Field:=1, Criteria1:=Sheets(1).Cells(K, 1)
                Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            If ActiveSheet.AutoFilter.Range.SpecialCells(xlCellTypeVisible).Areas.Count = 1 Then
            Exit For
            End If
                Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            End If
        End If
        
    Exit For
    Next i
   
    If G = True Then
        Range(Sheets(2).Cells(1, 1), Sheets(2).Cells(1, 4).End(xlDown)).Copy Sheets(3).Cells(1, 1)
        G = False
    Else
        Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Copy Sheets(3).Cells(1, 1).End(xlDown).Offset(1, 0)
    End If
    Sheets(2).Cells(2, 3).AutoFilter

Next K
Sheets(3).Select
Range(Sheets(3).Cells(2, 1), Sheets(3).Cells(2, 4).End(xlDown)).RemoveDuplicates Columns:=1
Range(Sheets(3).Cells(2, 1), Sheets(3).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
Application.ScreenUpdating = True
End Sub

TOP

¦^´_ 33# °a¤ªºµ

·PÁ°a¤ªºµ§ï¶iµ{¦¡½X

¸ê®ÆÁÙ®t¤@¨Ç

§Aªºµ{¦¡°õ¦æ§¹«á¥²¶·§R°£­«½Æ¶µ¥Ø

ªþ¤W§Ú³Ì²×»Ý­nªºÅã¥Ü®ÄªG»P­ã¤j¤ñ¸û¡A³o¼Ë¤ñ¸û®e©öÆ[¬Ý

¦C¥X§ó¦h¸ê®ÆV7¸ê®Æ§e²{.zip (49.29 KB)

TOP

¦pªG¬O «~¦WÁÙ¦³³W®æ ¥´¿ù¦r §Ú¬O§ï³o¼Ë ¦ý¬O ³W®æªºµ²ªG¸ò ·Ç¤jªº¤£¦P   
Public Sub ¼Ò½k¿z¿ï()
Application.ScreenUpdating = False
Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(255, 0, 0)
G = True
Sheets(3).Select
Sheets(3).Range(Cells(1, 1), Cells(1, 4).End(xlDown)).Clear
Sheets(2).Select

For K = 2 To Cells(2, 5).End(xlDown).Row
    x = Sheets(1).Cells(K, 3)
    If Sheets(1).Cells(K, 1) = "" Then Exit For
    For i = 2 To Cells(2, 3).End(xlDown).Row '¨Ì±ø¥ó¿z¿ï

        If Sheets(1).Cells(K, 3) = "" And Asc(Sheets(1).Cells(K, 2)) > 127 Or Asc(Sheets(1).Cells(K, 2)) < 0 Then
            Cells(i, 1).AutoFilter Field:=2, Criteria1:=Sheets(1).Cells(K, 2)
            Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            
            If Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Count - 1 And Sheets(1).Cells(K, 3) = "" Then
                Sheets(2).Cells(2, 3).AutoFilter
                Cells(i, 1).AutoFilter Field:=1, Criteria1:=Sheets(1).Cells(K, 1)
                Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
                If Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Count - 1 And Sheets(1).Cells(K, 3) <> "" Then
                    Sheets(2).Cells(2, 3).AutoFilter
                    Cells(i, 1).AutoFilter Field:=1, Criteria1:=Sheets(1).Cells(K, 1)
                    Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
                End If
            End If
            
        Else
           Cells(i, 1).AutoFilter Field:=3, Criteria1:="*" & x & "*"
           Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
        End If
        
        If G = True Then
           Range(Sheets(2).Cells(1, 1), Sheets(2).Cells(1, 4).End(xlDown)).Copy Sheets(3).Cells(1, 1)
           G = False
        Else
           Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Copy Sheets(3).Cells(1, 1).End(xlDown).Offset(1, 0)
        End If
        Sheets(2).Cells(2, 3).AutoFilter
    Exit For
    Next i
Next K
Sheets(3).Select
Range(Sheets(3).Cells(2, 1), Sheets(3).Cells(2, 4).End(xlDown)).RemoveDuplicates Columns:=1
Range(Sheets(3).Cells(2, 1), Sheets(3).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
Application.ScreenUpdating = True
End Sub

TOP

¥»©«³Ì«á¥Ñ °a¤ªºµ ©ó 2020-8-23 04:05 ½s¿è

ÁÂÁ n7822123 «e½úªº¹ªÀy  ¨C¼g¤@¦¸§Ú´N·|¦h¤@¦¸¸gÅç §Ú·|Ä~Äò§V¤Oªº:P

¦^´_ 30# qaqa3296
   
©êºp ¨S¦³ª`·N¨ì §Ú§ï³o¼Ë §A¬Ý¬Ý¬O¤£¬O³o¼Ëªºµ²ªG

Public Sub ¼Ò½k¿z¿ï()
Application.ScreenUpdating = False
Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(255, 0, 0)
G = True
Sheets(3).Select
Sheets(3).Range(Cells(1, 1), Cells(1, 4).End(xlDown)).Clear
Sheets(2).Select

For K = 2 To Cells(2, 5).End(xlDown).Row
    x = Sheets(1).Cells(K, 3)
    If Sheets(1).Cells(K, 1) = "" Then Exit For
    For i = 2 To Cells(2, 3).End(xlDown).Row '¨Ì±ø¥ó¿z¿ï

        If Sheets(1).Cells(K, 3) = "" And Asc(Sheets(1).Cells(K, 2)) > 127 Or Asc(Sheets(1).Cells(K, 2)) < 0 Then
            Cells(i, 1).AutoFilter Field:=2, Criteria1:=Sheets(1).Cells(K, 2)
            Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            
            If Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Count - 1 And Sheets(1).Cells(K, 3) = "" Then
                Sheets(2).Cells(2, 3).AutoFilter
                Cells(i, 1).AutoFilter Field:=1, Criteria1:=Sheets(1).Cells(K, 1)
                Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
            End If

            
        Else
           Cells(i, 1).AutoFilter Field:=3, Criteria1:="*" & x & "*"
           Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
        End If
        
        If G = True Then
           Range(Sheets(2).Cells(1, 1), Sheets(2).Cells(1, 4).End(xlDown)).Copy Sheets(3).Cells(1, 1)
           G = False
        Else
           Range(Sheets(2).Cells(2, 1), Sheets(2).Cells(2, 4).End(xlDown)).Copy Sheets(3).Cells(1, 1).End(xlDown).Offset(1, 0)
        End If
        Sheets(2).Cells(2, 3).AutoFilter
    Exit For
    Next i
Next K
Sheets(3).Select
Range(Sheets(3).Cells(2, 1), Sheets(3).Cells(2, 4).End(xlDown)).RemoveDuplicates Columns:=1
Range(Sheets(3).Cells(2, 1), Sheets(3).Cells(2, 4).End(xlDown)).Font.Color = RGB(0, 0, 0)
Application.ScreenUpdating = True
End Sub
javascript:;

¦C¥X§ó¦h¸ê®ÆV6001.rar (32.59 KB)

TOP

¥»©«³Ì«á¥Ñ n7822123 ©ó 2020-8-22 23:16 ½s¿è

¦^´_ 29# °a¤ªºµ

§A¥i¥HÄ~Äò§V¤O~~

¦Û¤v¨¯­W¼g¥X¨Óªºµ{¦¡¡A·|«Ü¦³¦¨´N·P!

¾Ç²ß´N¬O¤£Â_¹Á¸Õ¿ù»~ªº¹Lµ{~

¬Û¤Ï¡A¦pªG¥u§Û§O¤Hªºµ{¦¡¡A´N»{¬°¦Û¤v¤w¸g·|ªº¨ººØ¤H....¬O¾Ç¤£¦nªº

¥H¬°¦Û¤v¤w¸g¬ÝÀ´¡A¦ý´N¬O¤£¯à¦Û¤v¼g¥X¨Ó~
µ{¦¡¬O¨Ì»Ý¨D¼gªº¡A»Ý¨Dªí¹F¤£²M·¡
©ÎªÌ¨S¦³¤W¶Çªþ¥ó¡A·R²ö¯à§U

TOP

¦^´_ 29# °a¤ªºµ

1.¬Ý§A¦C¥Xªº¸ê®Æ§A¸Ó¤£·|...

¥Ø¼Ð«~¦W¥´¿ù¦r´N·|¦C¥X¸ê®Æ¯Ê¤Ö¡C®w¦s¤º«~¦W¦³­«½Æ´N·|¦h¦C¸ê®Æ? ³o...

¤W­±¦³¸É¥R»¡©ú¡G¤£­n¥H«~¦W¬°°ò·Ç¬d¸ß¡A­«½Æ»P¦h©ó¸ê®Æ¤Ó¦h¨S¦³°Ñ¦Ò»ù­È

TOP

¦^´_ 26# qaqa3296

§Ú¬O¥ÎÁä¦r¿z¿ïªº¤è¦¡  ¬Ý°_¨Óµ²ªG¬O¤@¼Ëªº  ¦ý§Ú¤£ª¾¹D¬O¤£¬O§A­n¨Dªº  
¤£¹L·Ç¤j¤w¸g¹F¨ì§Aªº¥Øªº  ¤]µ¹¤F§Ú¾Ç²ßªº¾÷·|
  


javascript:;

¦C¥X§ó¦h¸ê®ÆV6001.rar (31.01 KB)

TOP

¦^´_ 27# ­ã´£³¡ªL

µ{¦¡¦C¥Xªº¸ê®Æ«D±`§¹¾ã¡A·PÁ­㴣³¡ªL´£¨Ñ¥t¥~ªº¼gªk¨Ñ¤j®a¾Ç²ß

TOP

Sub TEST_V1()
Dim Arr, A, xD, i&, j%, N&, T$, V%
[¦¨ªG!A2:D6000].ClearContents
Set xD = CreateObject("scripting.dictionary")
Arr = Range([¥Ø¼Ð!C1], [¥Ø¼Ð!A65536].End(xlUp))
For i = 2 To UBound(Arr)
    T = Trim(Arr(i, 1)): If T <> "" Then xD(T) = 1
    T = ©î¸Ñ½s¸¹(Trim(Arr(i, 3))): If T = "" Then GoTo 101
    For Each A In Split(T, "/"): xD(A & "") = 1: Next
101: Next i
Arr = Range([®w¦s!D1], [®w¦s!A65536].End(xlUp))
For i = 2 To UBound(Arr)
    If xD("|" & i) > 0 Then GoTo 102 '¦pªG¸Ó¦æ¤w³Q´£¨ú¹L, ²¤¹L, ÁקK­«Âд£¨ú
    T = Trim(Arr(i, 1)): If Val(xD(T)) > 0 Then V = 1: GoTo 999 '[«~¸¹]¬Û²Å§Yª½±µ´£¨ú
    T = Trim(Arr(i, 3)): If T = "" Then GoTo 102
    T = ©î¸Ñ½s¸¹(T) '©î¸Ñ[³W®æ]
    For Each A In Split(T, "/")
        If A <> "" And Val(xD(A & "")) > 0 Then V = 1: Exit For
    Next
999:
   If V = 0 Then GoTo 102
   N = N + 1: V = 0
   For j = 1 To 4: Arr(N, j) = Trim(Arr(i, j)): Next
   xD("|" & i) = 1 '¤w´£¨ú¦æ¸¹¦ì¸m,°O¿ý¤J¦r¨å
102: Next i
If N > 0 Then [¦¨ªG!A2:D2].Resize(N) = Arr
End Sub

'==========================================
Function ©î¸Ñ½s¸¹(xS$) As String
Dim TT$, j%, ST$
If xS = "" Then Exit Function
If Left(xS, 4) Like "####" Then TT = Left(xS, 4)
If Left(xS, 5) Like "####[A-Z]" Then TT = Left(xS, 5) & "/" & TT
If Left(xS, 5) Like "[A-Z]####" Then TT = Left(xS, 5) & "/" & TT
If Left(xS, 8) Like "???-????" Then TT = Left(xS, 8) & "/" & TT
xS = xS & "-"
For j = Len(TT) + 2 To Len(xS)
    If Mid(xS, j, 1) Like "[-.(]" Then TT = Left(xS, j - 1) & "/" & TT
Next j
©î¸Ñ½s¸¹ = TT
End Function

¼Ò½k¤¤¤S¤£¯à¶Ã§ì, Ãø~~~

TOP

        ÀR«ä¦Û¦b : ¤H­n¦Û·R¡A¤~¯à·R´¶¤Ñ¤Uªº¤H¡C
ªð¦^¦Cªí ¤W¤@¥DÃD