Home / lang / rdir 
RDir
Syntax
File name array = RDir ( Directory AS String [ , Pattern AS String , Filter AS Integer ] )

Returns a string array that contains the names of files located in Directory that matches the Pattern and the Filter.

The specified directory is recursed.

The file paths returned are relative to the searched directory.

Examples

' Print the png image files in a directory and its sub-directories

SUB PrintDirectory(Directory AS String)

  DIM File AS String

  FOR EACH File IN RDir(Directory, "*.png")
    PRINT File
  NEXT

END

See also

File & Directory Functions