I have multiple data files with tab delimited data that imports nicely into excel. The problem is that I have MANY of them and need to convert all of them to Excel files for other uses.

I started by importing one .txt file into excel using tab-delimited conversion which worked perfectly and then saved it as a .xlsx file. I recorded all this by a Macro. Is there a way to use the same macro to convert all the .txt files in a folder or subfolder?

Below is my VBA macro code. Thanks for the help!

Sub Convert_TXT_to_XLSX()
'
' Convert_TXT_to_XLSX Macro
'

'
    ChDir "C:\Users\Aaron\Desktop\Aaron\FVB"
    Workbooks.OpenText Filename:="C:\Users\Aaron\Desktop\Aaron\FVB\7461b.txt", _
        Origin:=437, StartRow:=1, DataType:=xlDelimited, TextQualifier:= _
        xlDoubleQuote, ConsecutiveDelimiter:=False, Tab:=True, Semicolon:=False, _
        Comma:=False, Space:=False, Other:=False, FieldInfo:=Array(Array(1, 1), _
        Array(2, 1), Array(3, 1), Array(4, 1), Array(5, 1), Array(6, 1), Array(7, 1), Array(8, 1), _
        Array(9, 1), Array(10, 1), Array(11, 1), Array(12, 1), Array(13, 1), Array(14, 1), Array(15 _
        , 1), Array(16, 1), Array(17, 1), Array(18, 1), Array(19, 1), Array(20, 1), Array(21, 1), _
        Array(22, 1), Array(23, 1), Array(24, 1), Array(25, 1), Array(26, 1), Array(27, 1), Array( _
        28, 1), Array(29, 1), Array(30, 1)), TrailingMinusNumbers:=True
    ActiveWorkbook.SaveAs Filename:="C:\Users\Aaron\Desktop\Aaron\FVB\7461b.xlsx" _
        , FileFormat:=xlOpenXMLWorkbook, CreateBackup:=False
End Sub