FileSearch Property

Microsoft PowerPoint Visual Basic

Returns a FileSearch object that can be used to search for files using either an absolute or relative path. Read-only.

Example

This example displays the names of all files in the My Documents folder that begin with "New."

With Application.FileSearch
    .FileName = "New*.*"
    .LookIn = "C:\My Documents"
    .Execute
    For I = 1 To .FoundFiles.Count
        MsgBox .FoundFiles(I)
    Next
End With