docServerUserLandCom picture
Contents
Frontier Site

file.filesInFolder

Syntax file.filesInFolder (path, level)

Params path is the path to a folder.

level determines how deep the traversal goes:

If level = 1, file.filesInFolder doesn't go into any sub-folders.

If level = 2, it also counts the files in any sub-folders.

If level = infinity, it counts files at all levels, nesting into folders inside of sub-folders, and so forth.

Action Counts the number of files in the indicated folder and, optionally, sub-folders.

Returns The number of files

Examples file.filesInFolder ("C:\\Program Files\\Frontier\\", 1)

   » 21

file.filesInFolder ("C:\\Program Files\\Frontier\\", infinity)

   » 985

file.filesInFolder ("System:System Folder:", 1)

   » 54

file.filesInFolder ("System:System Folder:", infinity)

   » 251

Notes This verb determines the count by traversing the whole structure, which can be time-consuming.

See Also file.foldersInFolder


© Copyright 1992-2026 UserLand Software. Email: webmaster@userland.com.