Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- CA-Clipper 5.3 . Guide To CA-Clipper - <b>dirremove()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 DIRREMOVE()
 Remove a directory
------------------------------------------------------------------------------
 Syntax

     DIRREMOVE(<cDirName>) --> nSuccess

 Arguments

     <cDirName> is the name of the directory to erase, including an
     optional drive.  If you do not specify a drive, the current one is used.

 Returns

     DIRREMOVE() returns 0 if successful; -1 if there is an argument error.
     Otherwise, DIRREMOVE returns the DOS error code.

 Description

     DIRREMOVE() removes a specified directory.  Note that you must first
     have sufficient rights to delete a directory.  A directory must be empty
     in order to be deleted.  Therefore, to delete a directory that contains
     subdirectories, you must first delete the subdirectories (see example
     below).

 Examples

     .  This example uses DIRREMOVE() to delete a subdirectory named
        C:\TEST\ONE, which only contains an empty subdirectory named
        C:\TEST\ONE\TWO:

        DIRREMOVE("c:\test\one\two")        // First delete lowest dir
        nResult := DIRREMOVE("c:\test\one")  // Then delete higher dir
        IF nResult != 0
           ? "Cannot remove directory, DOS error ", siResult
           BREAK
        ENDIF


 Files   Library is EXTEND.LIB.


See Also: DIRCHANGE() DIRMAKE()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson