Show: Delphi C++
Display Preferences

System.IOUtils.TPath.GetDocumentsPath

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

class function GetDocumentsPath: string; static;

C++

static System::UnicodeString __fastcall GetDocumentsPath();

Properties

Type Visibility Source Unit Parent
function public
System.IOUtils.pas
System.IOUtils.hpp
System.IOUtils TPath

Description

Returns the path to the directory where user documents are stored.

If the system running your application does not support the requested folder, or if the requested folder does not exist in the system, this function returns an empty string instead.

  • On Windows and OS X, it points to a user-specific, application-agnostic directory.
  • On iOS and Android, it points to an application-specific, user-agnostic directory.
Platform Sample path Path ID
Windows XP C:\Documents and Settings\<username>\My Documents CSIDL_MYDOCUMENTS
CSIDL_PERSONAL
Windows Vista or later C:\Users\<username>\Documents FOLDERID_Documents
OS X /Users/<username>/Documents NSDocumentDirectory
iOS Device /var/mobile/Containers/Data/Application/<application ID>/Documents
iOS Simulator /Users/<username>/Library/Developer/CoreSimulator/Devices/<Device ID>/data/Containers/Data/Application/<application ID>/Documents
Android /data/data/<application ID>/files Context.getFilesDir

See Also

Personal tools
In Other Languages
Previous Versions
Assistance