I am trying to find a way to compare some text in 2 files and if a match is found then run a process.
Here are examples of the files;
'File A' = Automated list of text with this format;
example1
ex2
289 Example
fht_nkka
'File B' = File names from a directory search;
example1
test2
test4785
Using my 2 example files, I want to search them both and find matches.
So 'File A' above contains 'example1' and 'example1' is in 'File B'. What I want to be able to do is create 'string[] match based on all matches. Is there an easy way of doing this?
NOTE: these files do not always have the same line data or amount of lines in.