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

[¤À¨É] ¦p¦ó¦X¨Ö¦h­ÓcsvÀɮשó¦P¤@¥÷

[¤À¨É] ¦p¦ó¦X¨Ö¦h­ÓcsvÀɮשó¦P¤@¥÷

¥ý±N©Ò¦³csvÀɮ׸m©ó¦P¤@­Ó¸ê®Æ§¨(¨Ò¦p: D:\MYCSV\CSV)
¶}±Ò©R¥O´£¥Ü¦r¤¸CMD¡A¶i¨ìCSV¤å¥óªº©Ò¦b¥Ø¿ý(D:\MYCSV\CSV)
°õ¦æ¤U¦C«ü¥O
copy *.csv all.csv

¦p¦¹¡A¦bD:\MYCSV\CSV¤U¡A¥i¨£¥Í¦¨all.csvÀɮקY¬°¨D

¸Õ¸Õ

Sub yy()
  Dim a As Workbook, f$
  Dim p$, sh As Worksheet
  Set a = ThisWorkbook
  p = "D:\MYCSV\"
  f = Dir(p & "*.CSV")
  Application.ScreenUpdating = False
  Do While f <> ""
    Workbooks.Open p & f
    For Each sh In Worksheets
    'On Error Resume Next
    X = WorksheetFunction.CountA(sh.Range("a1:iv65536"))
    Y = ActiveWorkbook.Name
    If X <> 0 Then
      sh.Copy after:=a.Sheets(a.Sheets.Count)
    End If
    Next
    Windows(f).Close True
    f = Dir
  Loop
  Application.ScreenUpdating = True
  Sheet1.Select
  Range("A1").Select
End Sub
ù

TOP

        ÀR«ä¦Û¦b : ¦a¤WºØ¤Fµæ¡A´N¤£©öªø¯ó¡F¤ß¤¤¦³µ½¡A´N¤£©ö¥Í´c¡C
ªð¦^¦Cªí ¤W¤@¥DÃD