NWSetExtendedFileAttributes2

Sets the extended attributes of a file

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) NWSetExtendedFileAttributes2 ( 
      NWCONN_HANDLE       conn,  
      NWDIR_HANDLE        dirHandle,  
      const nstr8 N_FAR  *path,  
      nuint8              extAttrs);
   

Delphi Syntax

   uses calwin32 
    
   Function NWSetExtendedFileAttributes2 
     (conn : NWCONN_HANDLE; 
      dirHandle : NWDIR_HANDLE; 
      path : pnstr8; 
      extAttrs : nuint8 
   ) : NWCCODE;
   

Parameters

conn

(IN) Specifies the connection handle.

dirHandle

(IN) Specifies the directory handle of the root directory of the new directory..

path

(IN) Points to the string containing the name and path of the new directory.

extAttrs

(IN) Specifies the extended attributes for the file.

Return Values

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

0x0000

SUCCESSFUL

0x8801

INVALID_CONNECTION

0x898C

NO_MODIFY_PRIVILEGES

0x898D

SOME_FILES_AFFECTED_IN_USE

0x898E

NO_FILES_AFFECTED_IN_USE

0x8996

SERVER_OUT_OF_MEMORY

0x8998

VOLUME_DOES_NOT_EXIST

0x899B

BAD_DIRECTORY_HANDLE

0x899C

INVALID_PATH

0x89A1

DIRECTORY_IO_ERROR

0x89FD

BAD_STATION_NUMBER

0x89FF

Failure, NO_FILES_FOUND_ERROR

Remarks

NWSetExtendedFileAttributes2 requires Search rights to the directory where the file resides.

The path parameter can specify either the complete path name for a file 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 path parameter could point to either of the following:

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

The bit map for the extAttrs parameter follows:

0-2

Search mode bits

4

Transaction bit

6

Read audit bit (not yet implemented)

7

Write audit bit (not yet implemented)

Setting the transaction bit prompts TTS™ to track all Writes to the file during a transaction. A transaction file cannot be deleted or renamed until the transaction bit is turned off by calling NWSetExtendedFileAttributes2.

Setting the index bit prompts NetWare to index the File Allocation Tables for the file, thereby reducing the time required to access files. Files larger than 2 MB should have this bit set.

NOTE:To modify further extended file attributes, use NWSetNSEntryDOSInfo.

NCP Calls

See Also

NWGetExtendedFileAttributes2, NWSetNSEntryDOSInfo