[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 _fsDelete()
 Delete a file
------------------------------------------------------------------------------
 C Prototype

     #include "filesys.api"
     void _fsDelete(
                          BYTEP fpFilename
                      )

 Arguments

     fpFilename is the name of the file to delete specified as a null-
     terminated string.  The fpFilename must be fully specified, including
     the drive letter, path, and extension.

 Returns

     _fsDelete() has no return value.

 Description

     This function deletes the file fpFilename.  It is equivalent to the
     CA-Clipper function FERASE().  Use the _fsError() function to determine
     if the file delete operation resulted in an error.

 Examples

     .  The following code fragment illustrates the use of
        _fsDelete().  Note that error handling should be performed at each
        step.  Refer to the "Error System API Reference" chapter of this
        guide for details on communicating with the CA-Clipper Error system:

        #include "filesys.api"

        FHANDLE hFile;

        // Create a temporary read/write file
        hFile = _fsCreate( "Temp", FC_NORMAL );

        if (! _fsError() )
        {
           .
           .
           .
           _fsClose( hFile );  // Can't delete an open file
           _fsDelete( "Temp" );
        }

 Files  Library is CLIPPER.LIB, header file is Filesys.api.


See Also: _fsError() _fsRename()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson