| ©«¤l4901 ¥DÃD44 ºëµØ24 ¿n¤À4916 ÂI¦W267  §@·~¨t²ÎWindows 7 ³nÅ骩¥»Office 20xx ¾\ŪÅv150 ©Ê§O¨k ¨Ó¦Û¥x¥_ µù¥U®É¶¡2010-4-30 ³Ì«áµn¿ý2025-10-31 
                
 | 
                
| ¦^´_ 1# v60i ¥Î¸ê®Æ§¨¹ï¸Ü¤è¶ôµ²ªG¨ú¥NThisWorkbook.Path
 ½Æ»s¥N½XSub ¶×¤J¤å¦rÀÉ()
Dim xFile, uFile, uHead As Range, Jm&, Km&, X, xT, xL
Range("A:A").Clear '²M°£Â¶פJ¸ê®Æ
'-----------------------------------------------------
With Application.FileDialog(msoFileDialogFolderPicker)
.Show
fd = .SelectedItems(1)
End With
Application.ScreenUpdating = False
Do
    If xChk = 0 Then
       xFile = Dir(fd & "\*.txt")
       If xFile = "" Then MsgBox "¡°§ä¤£¨ì TXT ÀɮסI¡@", 0 + 16: Exit Sub
       xChk = 1
    Else
       xFile = Dir
       If xFile = "" Then Exit Do
    End If
    '----------------------------------------------
    uFile = fd & "\" & xFile
    Set uHead = Range("A65536").End(xlUp)
    If uHead <> "" Then Set uHead = uHead(3, 1)
    With ActiveSheet.QueryTables.Add(Connection:="TEXT;" & uFile, Destination:=uHead)
         .AdjustColumnWidth = False
         .TextFileColumnDataTypes = Array(1)
         .Refresh BackgroundQuery:=False
         .Delete
    End With
    uHead.Interior.ColorIndex = 6
    '¨Cµ§²Ä¤@®æ¥[¡e¶À¦â¡f©³
NEXT_LINE:
Loop
'-------------------------------------------------------
Application.ScreenUpdating = True
MsgBox "¡ã¡ã¶×¤J§¹¦¨¡ã¡ã¡@"
End Sub
 | 
 |