Sub
Michael8000()
Dim
meinWB
As
Workbook
Dim
meinSh
As
Worksheet
Dim
TextWB
As
Workbook
With
Application
.ScreenUpdating =
False
End
With
sPath = "C:\Temp\"
sFile = Dir(sPath &
"*.txt"
)
Set
meinWB = ActiveWorkbook
Set
meinSh = meinWB.Sheets(
"Daten"
)
Do
While
Len(sFile)
Workbooks.OpenText sPath & sFile, , , xlDelimited, , ,
True
, , , , , , Array(1, 1)
Set
TextWB = ActiveWorkbook
ls = meinSh.Cells(1, meinSh.Columns.Count).
End
(xlToLeft).Column + 1
TextWB.Sheets(1).Columns(1).Copy meinSh.Cells(1, ls)
TextWB.Close
sFile = Dir
Loop
With
Application
.ScreenUpdating =
True
End
With
End
Sub