TrFile_GetFolderSize (function reference)

Troi File Plug-in > Functions reference > TrFile_GetFolderSize
Troi File Plug-in for FileMaker Pro

TrFile_GetFolderSize

Returns the size for the folder specified by the folderPath. The size is the total size of all the files in the folder and subfolders.

SyntaxFunction badge

TrFile_GetFolderSize ( switches ; folderPath )

Parameters

switchesnot used, reserved for future use. Leave blank or put "-Unused"
folderPaththe path to the folder for which you want the information

Returned Result

Data type returned

Number

Result

The size (in number of bytes) of the folder.

Originated in

Troi File Plug-in 9.0

Compatibility

FileMaker Pro 13 to 17

Considerations

You can use FileMaker styled paths, like “filewin:/C:/MyFiles/MyFolder”.

Example

Assume there is a folder “MyData” with several files in it. Then:

Set Variable [ $FolderSize; TrFile_GetFolderSize ("-Unused" ; "Mydisk:MyData" ) ] 

might return 1048576 (= 1 Mb) which is the size used of the files in the folder.

Related functionsFunction badge

TrFile_GetDataSize
TrFile_GetFileSize

Related topics

Troi File Plug-in online help (overview)


Online Help Page for Troi File Plug-in for 13 to 17 –> TrFile_GetFolderSize (filep4315) 2018-0515 15:38:52