Deletes the specified directory.
SYS_RemoveDir (sDir)
Variable | Description |
---|---|
sDir | The name of the directory to remove. STRING. |
The specified directory must exist and must be empty for it to be removed, or an exception is raised.
SYS_RemoveDir 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 sTmpDir BOOLEAN bExists sTmpDir = SYS_GetDir () + "\tempdir" SYS_MakeDir (sTmpDir) bExists = SYS_DirExists (sTmpDir) Print (bExists) // Prints TRUE SYS_RemoveDir (sTmpDir) bExists = SYS_DirExists (sTmpDir) Print (bExists) // Prints FALSE