The code depends, of course, on your platform O/S. On UNIX, you can take advantage of the system *find* command to search for a wildcard-spec filename. On Windows, you could use the DOS find command, but it can't take wild cards (and is incredibly klunky to boot). Your best bet there is to roll your own in DOS or Windows using the findfile and nextfile system calls (or the MFC/Delphi equivalents) to walk a directory, and then apply that recursively to walk the directory trees. On DOS/Windows you'll also need code to find the disk partitions so you can traverse that list as well.