====== GETSPECIALDIR Method (FileSystem) ======
==== Description ====
Returns the path for a "special" Windows directory, such as the directory to use for temporary files, or the user's "My Documents" directory and so on.
==== Syntax ====
SpecialDirPath = Exec_Method( "FILESYSTEM",
"GETSPECIALDIR",
DirID )
==== Parameters ====
^Name^Required^Description^
|DirID|Yes|Specifies the directory path to return. Can be one of the following values:\\ \\ \\ \\ • "ADMINTOOLS"\\ \\ • "ALTSTARTUP"\\ \\ • "APPDATA"\\ \\ • "COMMON_ADMINTOOLS"\\ \\ • "COMMON_ALTSTARTUP"\\ \\ • "COMMON_APPDATA"\\ \\ • "COMMON_DESKTOPDIRECTORY"\\ \\ • "COMMON_DOCUMENTS"\\ \\ • "COMMON_FAVORITES"\\ \\ • "COMMON_PROGRAMS"\\ \\ • "COMMON_STARTMENU"\\ \\ • "COMMON_STARTUP"\\ \\ • "COMMON_TEMPLATES"\\ \\ • "COOKIES"\\ \\ • "DESKTOPDIRECTORY"\\ \\ • "FAVORITES"\\ \\ • "FONTS"\\ \\ • "HISTORY"\\ \\ • "INTERNET_CACHE"\\ \\ • "LOCAL_APPDATA"\\ \\ • "MYMUSIC"\\ \\ • "MYPICTURES"\\ \\ • "NETHOOD"\\ \\ • "PERSONAL"\\ \\ • "PRINTHOOD"\\ \\ • "PROFILE"\\ \\ • "PROGRAM_FILES"\\ \\ • "PROGRAM_FILES_COMMON"\\ \\ • "PROGRAMS"\\ \\ • "RECENT"\\ \\ • "SENDTO"\\ \\ • "STARTMENU"\\ \\ • "STARTUP"\\ \\ • "SYSTEM"\\ \\ • "TEMPLATES"\\ \\ • "WINDOWS"|
==== Returns ====
The specified path.
==== Remarks ====
The GETSPECIALDIR method is a simple wrapper around the SHGetSpecialFolderPath Windows API function, so it is worth examining at the documentation for this on the MSDN website to get a better idea of the capabilities of this method.
Equated constants for use with the GETSPECIALDIR method can be found in the PS_FILESYSTEM_EQUATES insert record.
==== Example ====
// Return the current user's "My Documents" folder
MyDocsDir = Exec_Method( "FILESYSTEM", "GETSPECIALDIR", "PERSONAL" )
==== See Also ====
TEMPDIR property, SYSTEMDIR property, WINDOWSDIR property.