Skip to content

FS.GetParentPath

boxgaming edited this page Jul 5, 2026 · 3 revisions

Returns the parent directory portion of a file path.
Available in release 0.11.0

Syntax

parentPath$ = FS.GetParentPath (filepath$)

Parameters

  • The filepath$ parameter can be a full or relative file path.

Examples

Example: Print the parent path portion of a full file path.

Import FS From "lib/io/fs.bas"

Dim filepath As String
filepath = "/util/tools/test/parser.bas"

Dim parentPath As String
parentpath = FS.GetParentPath(filepath)

Print parentPath

Output

/utils/tools/test

See Also

FS.GetFilename

Clone this wiki locally