PublicClass RecursiveFileFinder PublicSharedFunction GetAllFiles(ByVal path AsString, ByVal searchPattern AsString) As FileInfo() If Directory.Exists(path) Then Dim directory AsNew DirectoryInfo(path) Return directory.GetFiles(searchPattern, SearchOption.AllDirectories) Else ReturnNothing EndIf End Function End Class