Dim txtLine
Dim FileObj
Dim TextObj
Dim FilePathFilePath = "C:\text1.txt"
Set FileObj = CreateObject("Scripting.FileSystemObject")
Set TextObj = FileObj.OpenTextFile(FilePath)
Do While Not TextObj.AtEndOfLine
txtLine = txtLine & Trim(TextObj.ReadLine)
Loop
MsgBox txtLine