Checks whether the specified directory exists.
bExists = SYS_DirExists (sDir)
|bExists||Whether the directory exists. TRUE if it does exist and FALSE if it does not. BOOLEAN.|
|sDir||The directory to check for. STRING.|
SYS_DirExists works only on names of true directories, not on names of shared directories. If your script includes a call to SYS_DirExists for a shared directory, SYS_DirExists returns FALSE, not because the directory does not exist but because the directory is shared.
SYS_DirExists is executed by the Agent process, not the Silk Test Classic process. To affect the host process, use the function with the hHost notation or machine handle operator. For more information about the machine handle operator and hHost, see Machine handle operator.
STRING sTempDir BOOLEAN bExists sTempDir = SYS_GetDir () + "\tempdir" bExists = SYS_DirExists (sTempDir) Print (bExists) // prints: FALSE SYS_MakeDir (sTempDir) // make subdirectory bExists = SYS_DirExists (sTempDir) Print (bExists) // prints: TRUE