Platform SDK: Network Management |
Windows 95/98: The NetFileClose2 function forces a resource to close. This function can be used when an error prevents closure by any other means.
Windows NT/2000: This function is not supported on Windows NT/Windows 2000. Use the NetFileClose function instead.
Only members of the Administrators or Account Operators local group can successfully execute the NetFileClose2 function.
extern API_FUNCTION NetFileClose2( const char FAR * pszServer, unsigned long ulFileId );
If the function succeeds, the return value is NERR_Success.
If the function fails, the return value can be one of the following error codes.
Value | Meaning |
---|---|
ERROR_ACCESS_DENIED | The user does not have access to the requested information. |
NERR_NetNotStarted | The workstation driver is not installed. |
NERR_ServerNotStarted | The Server service is not started. |
NERR_RemoteErr | A remote API error occurred. |
NERR_FileIdNotFound | There is not an open file with the specified identification number. |
The NetFileClose2 function supports file handles that are larger than 64 kilobytes.
Windows NT/2000: Unsupported.
Windows 95/98: Requires Windows 95 or later.
Header: Declared in Svrapi.h; include Lm.h.
Library: Use Svrapi.lib.
Network Management Overview, Network Management Functions, NetFile Functions, NetFileEnum