hi, need macro to open and copy data from multiple txt. files (exactly i need direct 35 values(years)) to excel. I did macro for one year, but im struggling to do it for 35 years, can someone help me with solution please?
Thanks Crg.
VBA Code:
Sub txt_to_excel()
Dim X As Double
Dim TXT As String
' Adresss
Open "C:\Users\ppXXXX\Desktop\Country\file\00001\areas\year.txt" For Input As #1
X = 0
Do While Not EOF(1)
Line Input #1, TXT
Cells(1, 1).Offset(X, 0) = TXT
X = X + 1
Loop
Close #1
End Sub
Thanks Crg.