Skip to content

Get File Info ​

Parses a file path and returns its individual components — directory, file name, extension, and parent folders — as separate output variables.

Purpose ​

Use Get File Info when a workflow receives a full file path and downstream tasks need to act on specific parts of it. For example, you may need the base name to use as a record key, the extension to decide whether a file is eligible for processing, or the list of parent directories to build a corresponding archive path. This task removes the need to perform string operations on the path manually.

Inputs ​

FieldTypeRequiredDescription
File PathTextYesThe full or relative path to the file. Relative paths are resolved to their absolute equivalent.

Outputs ​

NameDescription
FullPathThe absolute path of the file.
DirectoryThe directory portion of the path, excluding the file name.
FileNameThe file name including its extension.
BaseNameThe file name without its extension.
ExtensionThe file extension, including the leading dot (e.g. .pdf).
ParentFoldersA list of folder names from the immediate parent up to the root, ordered nearest-first.

Examples ​

Extract the base name and extension from a path
FieldValue
File PathC:\Reports\monthly_summary.pdf
FullPathC:\Reports\monthly_summary.pdf
DirectoryC:\Reports
FileNamemonthly_summary.pdf
BaseNamemonthly_summary
Extension.pdf
ParentFolders["Reports", "C:"]

Tentech