NWIntEraseFiles

Deletes NetWare files from the server

NetWare Server:3.11, 3.12, 3.2, 4.x, 5.x, 6.x
Platform:Windows NT, Windows 95, Windows 98
Library:Cross-Platform NetWare Calls (CAL*.*)
Service:File System

Syntax

   #include <nwfile.h> 
   or 
   #include <nwcalls.h> 
    
   N_EXTERN_LIBRARY( NWCCODE )NWIntEraseFiles  ( 
      NWCONN_HANDLE       conn,  
      NWDIR_HANDLE        dirHandle,  
      const nstr8 N_FAR  *path,  
      nuint8              searchAttrs,  
      nuint16             augmentFlag);
   

Delphi Syntax

   uses calwin32 
    
   Function NWIntEraseFiles 
     (conn : NWCONN_HANDLE; 
      dirHandle : NWDIR_HANDLE; 
      const path : pnstr8; 
      searchAttrs : nuint8; 
      augmentFlag : nuint16 
   ) : NWCCODE;
   

Parameters

conn

(IN) Specifies the NetWare server connection handle containing the file to erase.

dirHandle

(IN) Specifies the directory handle of the file to be erased (0 if the path parameter contains the complete path including the volume name).

path

(IN) Points to the string containing the file path (including the file name) of the file to be erased.

searchAttrs

(IN) Specifies the search attributes.

augmentFlag

(IN) Specifies if wildcards are augmented:

  • 0 = wildcards are not augmented
  • nonzero = wildcards are augmented

Return Values

These are common return values; see Return Values (Return Values for C) for more information.

0x0000

SUCCESSFUL

0x8801

INVALID_CONNECTION

0x898A

NO_DELETE_PRIVILEGES

0x898D

SOME_FILES_AFFECTED_IN_USE

0x898E

NO_FILES_AFFECTED_IN_USE

0x898F

SOME_FILES_AFFECTED_READ_ONLY

0x8990

NO_FILES_AFFECTED_READ_ONLY

0x8998

VOLUME_DOES_NOT_EXIST

0x899B

BAD_DIRECTORY_HANDLE

0x899C

INVALID_PATH

0x89FF

NO_FILES_FOUND_ERROR

Remarks

The searchAttrs parameter includes system and/or hidden files. If only the system bit is set in the searchAttrs parameter, all files are affected except hidden files. If only the hidden bit is set, all files are affected except system files. When neither bit is set (0x00), only files that are not designated either hidden or system are affected.

NOTE:A file is designated hidden or system if its corresponding file attribute is set.

Search attributes to use in finding a file follow:

   0x00   none 
   0x02   FA_HIDDEN 
   0x04   FA_SYSTEM 
   0x06   both
   

The path parameter can specify either a complete path name or a path relative to the current working directory. For example, if the complete path name is SYS:ACCOUNT/DOMEST/TARGET.DAT and the directory handle mapping is SYS:ACCOUNT, the value of the path parameter could be either of the following:

   SYS:ACCOUNT/DOMEST/TARGET.DAT or DOMEST/TARGET.DAT
   

The path parameter can point to wildcards in the file name only. Wildcard matching uses the method defined by the application when it passes a wildcard character.

The client must have file deletion privileges in the target directory or NWIntEraseFiles will fail.

If a file has the immediate purge attribute set, the file cannot be recovered.

NCP Calls

See Also

NWPurgeDeletedFile, NWRecoverDeletedFile, NWRenameFile