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

[µo°Ý] ¨âÄ椣¦P¸ê®Æ¦X¨Ö

[µo°Ý] ¨âÄ椣¦P¸ê®Æ¦X¨Ö

½Ð°Ý¦U¦ì¤j¤j

¤p§Ì¦³¨â­ÓÄæ¦ì
AÄæ¤ÎBÄæ

AÄæ»PBÄæ¬Û¤ñ¡A±NAÄæ¨S¦³ªº¸É¶i¥hAÄæ¸Ì

EX:
AÄæ
A,B,C,D,E

BÄæ
A,C,E,F,G,I,R,A,G

¾ã²z¤§«á
AÄ欰
A,B,C,D,E,F,G,I,R


¤£ª¾³o¼Ëªº»yªk¸Ó¦p¦óªí¥Ü¤ñ¸û¦n

ÁÂÁ¦U¦ì¤j¤j  :  )
¥Î¥\¨ì¥@¬É¥½¤é¨º¤@¤Ñ¡ã¡ã¡ã

¥»©«³Ì«á¥Ñ yangjie ©ó 2013-12-25 14:34 ½s¿è

¦^´_ 1# li_hsien

¸Õ¸Õ¬Ý
sub test1()
    Dim d As Object, a
    Set d = CreateObject("Scripting.Dictionary")
    With Sheets(1)
            For Each a1 In .Range(.Cells(2, 1), .Cells(65536, 1).End(xlUp))
                d(a1.Value) = ""
            Next
            n1 = d.Count
           For Each a1 In .Range(.Cells(2, 2), .Cells(65536, 2).End(xlUp))
                d(a1.Value) = ""
           Next
           n2 = d.Count
           If n2 =n1  Then exit sub
          a = d.keys
           k = .Cells(65536, 1).End(xlUp).Row
          For I = n1 + 1 To n2
                .Cells(k + 1, 1) = a(I - 1)
                k = k + 1
          Next
    End With
     
end sub

TOP

¦^´_ 2# yangjie

ÁÂÁÂyangjieªº¦^ÂÐ

¤S¾Ç¨ìÂIªF¦è¤F :  )


§Ú«á¨Ó¤]¦³·Q¨ì­Ó¤èªk

¥Îmatch¨Ó§PÂ_
  1. Sub match()

  2.     With Workbooks("TEST123").Worksheets("sheet2")
  3.    
  4.     For i = 2 To .Range("C2").End(xlDown).Row
  5.         
  6.         If IsError(Application.match(.Range("C" & i), Range("C:C"), 0)) = True Then
  7.             Range("C" & Range("C2").End(xlDown).Row + 1) = .Range("C" & i)
  8.         End If
  9.             
  10.         Debug.Print Range("C2").End(xlDown).Row
  11.         
  12.     Next
  13.    
  14.     End With
  15.    
  16. End Sub
½Æ»s¥N½X
¥Î¥\¨ì¥@¬É¥½¤é¨º¤@¤Ñ¡ã¡ã¡ã

TOP

        ÀR«ä¦Û¦b : µêªÅ¦³ºÉ¡D§ÚÄ@µL½a¡AµoÄ@®e©ö¦æÄ@Ãø¡C
ªð¦^¦Cªí ¤W¤@¥DÃD