Skip to content

Modern Fs GetVolumeInfo

Paul Squires edited this page Nov 9, 2026 · 6 revisions

Home › Filesystem › Filesystem Library › GetVolumeInfo

GetVolumeInfo

Returns the VolumeInfo of the volume a path is on: its root, label and file system.

Syntax

GetVolumeInfo( p )

Notes

  • FsResultVol

Examples

#import "std/fs"
using fs

dim r as FsResultVol = GetVolumeInfo( "." )

print r.IsOk( )              '' true

dim v as VolumeInfo = r.Value( )
print len( v.RootPath ) > 0  '' -1 (true)
print v.MaxComponentLen > 0  '' -1 (true)

'' Name and FileSystem MAY BE EMPTY -- always on Linux and macOS, often for a
'' network share -- so never assert on them

Library: Filesystem Library
Category: Filesystem
Documented under: Volumes

Clone this wiki locally