AddDirectory

                                           +---------------+
                                           V               |
>>-aComboBox~AddDirectory(--drvPath--,--"----+-READWRITE-+-+--"--)-><
                                             +-READONLY--+
                                             +-HIDDEN----+
                                             +-SYSTEM----+
                                             +-DIRECTORY-+
                                             +-ARCHIVE---+


The AddDirectory method adds all or selected file names of a given directory to the combo box.

Arguments:

The arguments are:

drvpath

The drive, path, and name pattern.

fileAttributes

Specify the file attributes the files must possess in order to be added:

READWRITE

Normal read/write files (same as none).

READONLY

Files that have the read-only bit.

HIDDEN

Files that have the hidden bit.

SYSTEM

Files that have the system bit.

DIRECTORY

Files that have the directory bit.

ARCHIVE

Files that have the archive bit.

Return value:

The one-based index of the file name added last to the list, or 0 if an error occurred.

Example:

The following example puts the names of all read/write files with extension .REX in the given directory of the list box:

MyDialog~AddDirectory(203, drive":\"path"\*.rex", "READWRITE")