Hi

I want to search for multiple words in a .txt file:

file_seek(filehandle,0,0);
xndex = file_find (filehandle, "john");
xndexi = file_find (filehandle, "sam");

if...
if...
if...

When I run the code it will only look for the first name. How can I search for multiple criteria (i.e. multiple names at the same time).

I have been trying options without much success e.g.

xndex = file_find (filehandle, "john"; "sam");

Would anyone be able to point me in the right direction please?

I could search for a single word followed by if statements but without searching for multiple criteria at the same time (i.e. different names) the code is inefficient and very long.

Thanks for your help in advance!

D