Platform SDK: Network Management |
Windows 95/98: The NetAccessAdd function creates a new access-control list (ACL) for a resource.
Windows NT/2000: The NetAccessAdd function is obsolete on Windows NT/Windows 2000. Win32-based applications should use the GetFileSecurity and SetFileSecurity functions.
Requires User level security to be enabled.
extern API_FUNCTION NetAccessAdd( const char FAR * pszServer, short sLevel, char FAR * pbBuffer, unsigned short cbBuffer );
Value | Meaning |
---|---|
2 | The pbBuffer parameter points to an access_info_2 structure. |
12 | The pbBuffer parameter points to an access_info_12 structure. |
If the function succeeds, the return value is NERR_Success.
If the function fails, the return value is a Win32 API error code. For a list of error codes, see Error Codes.
Windows NT/2000: Requires Windows NT 3.1 or later.
Windows 95/98: Requires Windows 95 or later.
Header: Declared in Lmaccess.h (Windows NT/2000) or Svrapi.h (Windows 95/98); include Lm.h (Windows NT/2000).
Library: Use Netapi32.lib (Windows NT/2000) or Svrapi.lib (Windows 95/98).
Network Management Overview, Network Management Functions, Access Functions, access_list, access_info_2, access_info_12, NetAccessDel