12/02/21 19:48:13.75
>>344
もう解決してるので今更感が強いけど、
テキストファイルをエクセルで開いて下から4行目を取得する、
というやり方もできるよ
Test.txtを開くと仮定したらこんな感じ
Sub test()
Dim WB As Workbook
Dim I&
Dim Txt$
Set WB = Workbooks.Open("test.txt")
With WB.Sheets(1)
I = .Cells(.Rows.Count, 1).End(xlUp).Row
If I > 3 Then
I = I - 3
Else
I = 1
End If
Txt = .Cells(I, 1).Value
WB.Close
MsgBox Txt
End With
End Sub