Skip to main content

TrFile_ListDisks (function reference)

By June 1, 2024June 4th, 2024Online Help, Troi File Plug-in
Troi File Plug-in for FileMaker Pro

TrFile_ListDisks

Lists the names of all currently available disks.

SyntaxFunction badge

TrFile_ListDisks ( switches )

Parameters

switches (optional) determine way the result is returned

Switches

Switches can be empty or:

-ReturnAtEnd add an extra return character after the last found item in the list

Returned Result

Data type returned

Text

Result

A list of names of all the disks that are currently mounted (available).

Originated in

Troi File Plug-in 2.0

Compatibility

FileMaker Pro 17 to FileMaker Pro 21 (2024)

Considerations

On macOS it is possible to have multiple disks with the same name. In this case you will see the same disk name multiple times in the list.

NOTE To find the startup disk you can use the TrFile_FindFolder function.

Example

Set Field [ result ; TrFile_ListDisks ( "" ) ]

On macOS this will return a list of names of all the disks that are currently mounted, for example:

KES¶
SPOCK¶
Photos till 2020¶
Music Archive Disk 5

On Windows the drive letters of the available disks are returned, for example:

A:¶
C:¶
D:¶
K:

Used in example file

DiskInfo.fmp12

Related functionsFunction badge

TrFile_DiskInfo
TrFile_FindFolder
TrFile_MountDisk

Related topics

Troi File Plug-in online help (overview)


Online Help Page for Troi File Plug-in for 17 to 2024 –> TrFile_ListDisks (filep4253) 2024-0604 19:24:46