Click to See Complete Forum and Search --> : Find words in file


Sunpetch
February 27th, 2000, 09:28 PM
How can I find some words in file?
Ex. I want to find "eat" in test.txt file.
If it's match "msgbox will show "OK"
If it's not match "msgbox will show "can't find"

Lothar Haensler
February 28th, 2000, 12:59 AM
read the complete file into one string and use VB's Instr function to search for the occurrence of the search string within your file.