- ©«¤l
- 5923
- ¥DÃD
- 13
- ºëµØ
- 1
- ¿n¤À
- 5986
- ÂI¦W
- 0
- §@·~¨t²Î
- win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW°ò¶©
- µù¥U®É¶¡
- 2010-5-1
- ³Ì«áµn¿ý
- 2022-1-23
|
¦^´_ 1# free72921
¸Õ¸Õ¬Ý- Option Explicit
- Sub Ex()
- Dim AR As Variant, i As Integer, E As Variant
- With Sheets("¤ÀÃþªí")
- i = 2 '²Ä¤G¦C¶}©l
- Do While .Cells(i, "A") <> "" '°õ¦æ¤@ª½¨ì¨S¸ê®Æ
- AR = AR & IIf(AR <> "", vbLf, "") & .Cells(i, "A") & "," & .Cells(i, "B") ' ±µ¦X ¤ÀÃþ"," ª««~
- '**Ū¨úª««~¸ê®Æ vbLf Àé¦C '**ARªº«¬ºA¬°¦Û¦ê
- i = i + 1 '¤U¤@¦C
- Loop
- If AR <> "" Then AR = Split(AR, vbLf) '±N«¬ºA¬°¦Û¦ê Âର°}¦C
- End With
- With Sheets("¤u§@¶")
- i = 2
- Do While .Cells(i, "A") <> ""
- For Each E In AR '°}¦C ªº¨C¤@¤¸¯À
- If InStr(E, .Cells(i, "A")) Then 'InStr ¤ñ¹ï¤¸¯À¤¤¬O§_¦³«ü©wªºª««~
- .Cells(i, "B") = Mid(E, 1, InStr(E, ",") - 1) '¼g¤J¤ÀÃþ
- Exit For
- End If
- Next
- i = i + 1
- Loop
- End With
- End Sub
½Æ»s¥N½X |
|