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

[µo°Ý] ¦h¦æ¸ê®Æ¦X¨Ö¬°¤@¦æ

[µo°Ý] ¦h¦æ¸ê®Æ¦X¨Ö¬°¤@¦æ

½Ð±Ð¦U¦ì°ª¤â~
·Q§Q¥Îvba¨Ó¾ã²z¸ê®Æ

¥Ø«e¤u§@ªí¤@¬° 1.png

·Q­n¦P¼Ë¦W¦rªº¸ê®Æ¥u­n¥X²{¤@¦æ´N¦n
¾ã²z¦b¤u§@ªí¤G
³o¬O·Q­n³Ì²×ªºµ²ªG

¥Ø«eµ§¼Æ¸û¤Ö¥i¥HºCºC¶K
¦ý¸ê®Æ¤@¦h´N·|«Ü¯Ó®É
³o¼Ëµ{¦¡½X¸Ó«ç»ò¥´©O?
¸ê®Æ¦pªþ¥ó ¦h¦æ¸ê®Æ¦X¨Ö.zip (131.28 KB)

§Úªº·Qªk;§Q¥Î¦W¦r©M¬ì¥Ø¬°key­È¡A¦A±a¥X¦¨ÁZ
¤£ª¾³o¼Ë¤èªk¬O§_¥i¦æ

¤W¶ÇÀÉ®×µLªk¥¿±`¶}±Ò(®æ¦¡¤Ó¦h), ¤j¬ù¼g¤@¤U:ª`·N¤u§@ªí¦WºÙ¬O§_¬Û¦P
  1. Sub TEST()
  2. Dim R&, C, N&, Arr, Brr, xD, i&, T$
  3. Sheets("¤u§@ªí2").UsedRange.Offset(1, 0).Clear
  4. Arr = Range([¤u§@ªí1!A2], [¤u§@ªí1!A65536].End(xlUp)(1, 5))
  5. ReDim Brr(1 To UBound(Arr), 1 To 8)
  6. Set xD = CreateObject("Scripting.Dictionary")

  7. For i = 1 To UBound(Arr)
  8.     T = Arr(i, 1): R = xD(T)
  9.     If R = 0 Then
  10.        N = N + 1: R = N: xD(T) = N
  11.        Brr(R, 1) = Arr(i, 1):  Brr(R, 2) = Arr(i, 2): Brr(R, 3) = Arr(i, 3)
  12.     End If
  13.     C = Application.Match(Arr(i, 4), Array("°ê»y", "­^¤å", "¼Æ¾Ç", "ª«²z", "¤Æ¾Ç"), 0)
  14.     Brr(R, C + 3) = Arr(i, 5)
  15. Next i
  16. [¤u§@ªí2!A2].Resize(N, 8) = Brr
  17. End Sub
½Æ»s¥N½X

TOP

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


    wow~ ÁÂÁ­ã¤j~
    Dim R&, C, N&, Arr, Brr, xD, i&, T$
   &¡A$
   ³o¨Ç©w¸q¥Nªíªº¬O¤°»òªü
   ¦]¬°¤§«e§Ú³£³]³o¼Ë
   Dim A As Integer
   Dim B As Variant
   Dim C As String
  
·Q­n§ó²`¤Jªº¤F¸Ñ

TOP

¦^´_ 3# Changbanana

Long = &
Integer = %
String = $

¦³®É¶¡¥i¥H¶iVBE¤º«Ø»¡©úÀɦh¬Ý¬Ý, ¯à«õ¨ì¤£¤Öª¾ÃѤΧޥ©!
¥t¡eÀ˵ø¡f¡eÂsÄýª«¥ó¡f¤]¬O¤£¿ùªºµøµ¡¡A¥i¥H¤@¤@¥h¬Ý¦UºØª«¥ó¡DÄݩʵ¥µ¥ªº»¡©ú¡I

TOP

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

¤F¸Ñ¤F~
¥i§_¸Ñ»¡¤U­±ªº¼gªk
    For i = 1 To UBound(Arr)
    T = Arr(i, 1): R = xD(T)
    If R = 0 Then
       N = N + 1: R = N: xD(T) = N
       Brr(R, 1) = Arr(i, 1):  Brr(R, 2) = Arr(i, 2): Brr(R, 3) = Arr(i, 3)
    End If
    C = Application.Match(Arr(i, 4), Array("°ê»y", "­^¤å", "¼Æ¾Ç", "ª«²z", "¤Æ¾Ç"), 0)
    Brr(R, C + 3) = Arr(i, 5)

­Y¤§«á·Q­n¦A¼W¥[¤@­Ó¬ì¥Ø
C = Application.Match(Arr(i, 4), Array("°ê»y", "­^¤å", "¼Æ¾Ç", "ª«²z", "¤Æ¾Ç","ªÀ·|"), 0)
    Brr(R, C + 3) = Arr(i, 6)

¬O¥i¥H³o¼Ë§ï¹À? ·PÁ±zªº±Ð¾Ç

TOP

¦^´_ 5# Changbanana


Brr(R, C + 3) = Arr(i, 5)  ³o¬O¤u§@ªí1ªº¡e¤À¼Æ¡fÄæ¡]¢ÓÄæ¡^¡A¤£¶·ÅÜ°Ê

­Y¤§«á·Q­n¦A¼W¥[¤@­Ó¬ì¥Ø
C = Application.Match(Arr(i, 4), Array("°ê»y", "­^¤å", "¼Æ¾Ç", "ª«²z", "¤Æ¾Ç","ªÀ·|"), 0)

¢Ñ¬O¥Î¨Ó§PÂ_¡e¬ì¥Ø¡f¤À¼Æ­n©ñ¦b¤u§@ªí¢±ªº²Ä´X­ÓÄæ¦ì¡A
­Y¬ì¥Ø¬O¡eªÀ·|¡f¡A¢Ñ¡×¢µ¡A¢µ¡Ï¢²¡×¢¸¡A¤À¼Æ©ñ¦b²Ä¢¸Äæ¡]¢×Äæ¡^

TOP

http://blog.xuite.net/hcm19522/twblog/450703586

TOP

¦^´_ 7# hcm19522


   ¨ç¼Æ¤]¬O¤@ºØ¤èªk ÁÂÁ§A^^

TOP

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

Dim R&, C, N&, Brr, Arr, xD, i&, T$
Sheets("¤u§@ªí2").UsedRange.Offset(1, 0).Clear
Arr = Range([¤u§@ªí1!A2], [¤u§@ªí1!A65536].End(xlUp)(1, 5))
ReDim Brr(1 To UBound(Arr), 1 To 8)
Set xD = CreateObject("Scripting.Dictionary")


ª©¥D¤j¤j¦n
§Ú¬Ý¤£À´¬õ¦âªº¦a¤è¡A¥i¥H½Ð§A±Ð¾Ç¶Ü
arr=A1:E8ªº½d³ò
¬°¤°»ò¤S­n­«·s©w¸qbrrÅܼƩO Redim
Ubound¬OÔ£·N«ä?
¤Wºô¬d¹L¹ê¦b¬Ý¤£¤ÓÀ´
brr( xxx,xxx)¤S¬OÔ£·N«ä?
CreateObject("Scripting.Dictionary")  ³o¬O¤°»ò·N«ä©O

·PÁ¤j¤j

TOP

¦^´_ 9# popomilk


brr( xxx,xxx)¤S¬OÔ£·N«ä?  ¡Ö¡e°}¦C¡fArray¡@
CreateObject("Scripting.Dictionary")  ³o¬O¤°»ò·N«ä©O¡@¡Ö¡@¦r¨åÀɪ«¥ó¡@

¥i GOOGLE ¬d¨ä¨Ï¥Îªk¡ã¡ã

TOP

        ÀR«ä¦Û¦b : ¥@¤W¦³¨â¥ó¨Æ¤£¯àµ¥¡G¤@¡B§µ¶¶ ¤G¡B¦æµ½¡C
ªð¦^¦Cªí ¤W¤@¥DÃD