Reference > Functions reference > Get functions > Get(DocumentsPath)
 

Get(DocumentsPath)

Returns the path to the Documents folder for the current user.

Format 

Get ( DocumentsPath )

Parameters 

None

Data type returned 

text

Originated in 

FileMaker Pro 8.0

Description 

In FileMaker Pro Advanced and FileMaker Go, returns the path to the current user's Documents folder. The path format varies by operating system.

When running on server-side scripts, Get(DocumentsPath) returns the location of the Documents folder. The Documents folder is used as a shared location that scripts from different sessions or other processes on the machine can use to import or export files. See FileMaker Server Help or FileMaker Cloud for AWS documentation in the Product Documentation Center.

Notes 

In FileMaker WebDirect, the FileMaker Data API, and Custom Web Publishing, this function is not supported and returns an empty string.

Example 1 

For FileMaker Pro Advanced, for a user named John Smith, returns:

/C:/Users/John Smith/Documents/ in Windows

/Macintosh HD/Users/johnsmith/Documents/ in macOS

For FileMaker Server, returns:

/C:/Program Files/FileMaker/FileMaker Server/Data/Documents/ in Windows

/Macintosh HD/Library/FileMaker Server/Data/Documents/ in macOS

For FileMaker Cloud for AWS, returns:

/opt/FileMaker/FileMaker Server/Data/Documents/

Each part of the path may vary from these examples, so don't rely on the path to follow a particular pattern.

For an example script, see Set Variable script step.

Related topics 

Functions reference (category list)

Functions reference (alphabetical list)

About formulas

About functions

Defining calculation fields

Using operators in formulas

Get(DocumentsPathListing) function

Get(TemporaryPath) function