Can anyone tell me what im doing wrong here? I get this message when running the script https://i.imgur.com/xNZPmwh.png
Code: Select all
;Deletes all .txt Files in this folder that doesnt contain any of these words [capitalized or non-capitalized] in line 10 or 11
Loop, Files, C:\PortableApps Platform\PortableApps\AutoHotkeyPortable\Scripts\Old, Inactive, Faulty, Tests\Tests\*.txt
{
f1 := A_LoopFilePath
FileReadLine, line10, % f1, 10
erl_1 := ErrorLevel
FileReadLine, line11, % f1, 11
erl_2 := ErrorLevel
if !(erl_1 || erl_2) && !(line10 ~= "i)Day|marbles|popsicles" && line11 ~= "i)night|bubbles")
FileDelete, % f1
}