I have tried this code to verify the content of file and I was able to read the content, but I should read the word which is immediate to searching word.
For example in the text file I have some 10 lines of content; in the third line I found the searched word, I should read the immediate next line of searched word. Consider this is a text fie content:
Hello
how
are
you
I am
fine
I need to search the word how is present in the text file , if the how word is found, I should read/verify the immediate next line of the word.
The output should be are
open file "D:\Automation\EGGPlant\Archiecture\Script-Demo.suite\Resources\Demo.txt"
read from file "D:\Automation\EGGPlant\Archiecture\Script-Demo.suite\Resources\Demo.txt"
put file "D:\Automation\EGGPlant\Archiecture\Script-Demo.suite\Resources\Demo.txt" into WiFiInfo
Repeat the number of lines of WiFiInfo times:
put line repeatindex() of WiFiInfo into output
if output contains "how" then
Log "found"
else
Log "Not found"
end if
end repeat
Expected result should be are
Here is the answer to your question