Directory: GetFiles

GetFiles

Returns a list of all the files that match a pattern within the specified directory.



 Public Function GetFiles(
	  ByVal Path As String,
	  Optional ByVal SearchPattern As String = "*" ) As String ( )

Parameters

Path
[ByVal] String. The directory to search for the matching files.
SearchPattern
[ByVal] Optional. String. A pattern to match the files against.  

Default: "*"

Return Values

String() -  The list of matching file names. If no filenames matched, then an empty, zero-length array is returned.

Remarks

The path can be absolute or relative. The path is not included in the filename result.

See Also

Project VBCorLib Overview Class Directory Overview Directory Properties Directory Methods GetDirectoryRoot GetFileSystemEntries