I'm not new to Batch Files but i have a requirement that i can't seem to get my head around, I'm sure it must be simple'ish..

I have 2 .txt files (Locations.txt | Files.txt)

  • Locations is a list of directories
  • Files is a list of file names

I would like to write a Batch Script that would loop through each location in the Locations.txt for files names that match any in Files.txt

I think i may need to write a for loop to cycle through the locations but then i'm not sure how i would pass the file names through for it to check for.

Basically if it does find any of those file names in any of the location i would want it to echo a message.