NAME

files - print file names

SYNOPSIS

#include <basic/string.h>

files(str)
struct string *str;

DESCRIPTION

Files outputs to the current file (see initio(io)) a list of file names which match the file name generation pattern given by the string pointed to by str.  The pattern may contain UNIX shell meta-characters and is interpreted by genfilnam (see readdir(misc)). 

The listing, in the style of ls(1), is multi-columnar (if appropriate) and sorted (reading down the columns).  If any file matched by the pattern is a directory, its contents are also listed under a separate heading.  In this case, files which begin with dot are not listed in keeping with the more modern UNIX tradition.  If str is null, only the contents of the current directory are listed. 

This function implements the FILES statement. 

SEE ALSO

initio(io), readdir(misc)
files(stmt)
ls(1) in the UNIX Programmerís Manual

DIAGNOSTICS

Error 53 (File not found) is generated if str has no match (interpreted as a file generation pattern) and str can not be found (interpreted as a simple file name). 

from The Basmark QuickBASIC Programmerís Manual by Lawrence Leinweber