Sub SimpleImport()
On Error GoTo ErrorHandler
Dim fn As Integer
Dim RawData As String
Dim rngTarget As Range
Dim TargetRow As Long
Dim x As Integer
Dim strFolder As String
Dim strFileName As String
strFolder = Application.ActiveWorkbook.Path & "\"
For x = 1 To 3 ' set your maximum number of files here
TargetRow = 0
Set rngTarget = ActiveSheet.Range("A1")
Application.ScreenUpdating = False
Application.Calculation = xlCalculationManual
strFileName = strFolder & "log00" & x & ".txt"
If Dir(strFileName) = "" Then
MsgBox strFileName & " NOT FOUND"
Exit Sub
End If
fn = FreeFile
Open strFileName For Input As #fn
Application.StatusBar = "Processing ... " & x
Do While Not EOF(fn)
Line Input [URL="https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=fn"]#fn[/URL] , RawData
rngTarget.Offset(TargetRow, x - 1) = RawData
TargetRow = TargetRow + 1
Loop
Close [URL="https://www.mrexcel.com/forum/usertag.php?do=list&action=hash&hash=fn"]#fn[/URL]
Next
ErrorHandler:
If Err.Number <> 0 Then
MsgBox RawData & vbCrLf & vbCrLf & Err.Description, vbCritical
End If
Application.StatusBar = False
Application.ScreenUpdating = True
Application.Calculation = xlCalculationAutomatic
End Sub