File function FILES

20  FILES (wildcards)
Returns an array with the filenames. If there are no files returns an empty array.

See examples

If there is insufficient information on this page and you wish learn more about FILES, please send an email to You can help to improve information about FILES by submitting an article using the comments link below. Note, an offline language reference text file is now avialable – see the Download section.


The directory listing, if assigned to a string, will create a string array. Each filename is assigned to its own element in the string array.
sample program example:
20 a$=FILES("*.*")
30 n=LEN(a$)
40 FOR i = 0 to n-1
50 PRINT a$(i)
60 NEXT i