RMDIR

Purpose:

Deletes a directory.

Syntax: 

RMDIR("dirname", "s", confirm)

"dirname"

-

A string, the name of the directory to remove.

"s"

-

Optional, a string. Delete all sub-directories if flag set to "s".

verbose

-

Optional, an integer confirm delete flag.

0:

Delete without confirmation (default).

1:

Confirm delete.

Returns:

An integer, 1 if successful.

Example:

rmdir("\spldir")

 

removes the directory \spldir if the directory is empty.

Example:

rmdir("\spldir", "s")

 

removes all files and sub-directories in the directory \spldir including the \spldir directory itself.

Remarks:

RMDIR removes a directory if it is empty. If the "s" flag is provided, all files and sub-directories are removed.

 

See DELFILE to delete one or more files in a directory.

 

See MKDIR to create a new directory.

See Also:

COPYFILE

DELFILE

DIREXISTS

MKDIR

MOVEFILE