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

¸ê®Æ©î¸Ñ

¸ê®Æ©î¸Ñ

¥»©«³Ì«á¥Ñ hugh0620 ©ó 2011-6-27 10:55 ½s¿è

Dear ¤j¤j

          ¤p§Ì¦³¤@­Ódata»Ý­n©î¶},
          ½Ð¤j¤j¦³±Ð©ó§Ú~
          °ÝÃD½d¥»,¦pªþÀÉ
          ¸ê®Æ©î¸Ñ.rar (9.45 KB)
          °ÝÃD¦p¤U
          ¦]­ì©l¸ê®ÆªºÀx¦s®æ¬O¥Îalt+enter Â_¶},©Ò¥H,»Ý­n±NÂ_¶}ªº¸ê®ÆÂন¸ê®Æ®wªº®æ¦¡
          ±q¸ê®Æ®wªº®æ¦¡Âন­ì©l¸ê®Æªº®æ¦¡,¤p§Ì¥Î²Âªº¤è¦¡³B²z,¦ý¥i¥H¶]~
          °ÝÃD¹Ï¥Ü:
         
¾Ç²ß¤~¯à´£¤É¦Û¤v

  1. Private Sub CommandButton1_Click()
  2. Dim arr(), i%, j%, m%, a
  3. For i = 3 To [e65536].End(3).Row
  4. If InStr(Cells(i, 5), vbLf) = 0 Then
  5. m = m + 1
  6. ReDim Preserve arr(1 To 2, 1 To m)
  7. arr(1, m) = Cells(i, 4): arr(2, m) = Cells(i, 5)
  8. Else
  9. a = Split(Cells(i, 5), vbLf)
  10. For j = 0 To UBound(a)
  11. m = m + 1
  12. ReDim Preserve arr(1 To 2, 1 To m)
  13. arr(1, m) = Cells(i, 4): arr(2, m) = a(j)
  14. Next
  15. End If
  16. Next
  17. [g3].Resize(m, 2) = Application.Transpose(arr)
  18. End Sub
½Æ»s¥N½X

TOP

        ÀR«ä¦Û¦b : ¡i°µ¤Hªº¶}©l¡j¨C¤@¤Ñ³£¬O¬G¤Hªº¶}©l¡A¨C¤@­Ó®É¨è³£¬O¦Û¤vªºÄµ±§¡C
ªð¦^¦Cªí ¤W¤@¥DÃD