This function ends a network resource enumeration started by the WNetOpenEnum function.
At a Glance
Header file: | Winnetwk.h |
Windows CE versions: | 2.0 and later |
Syntax
DWORD WNetCloseEnum(HANDLE hEnum);
Parameters
hEnum
[in] Handle to an enumeration instance. This handle must be returned by the WNetOpenEnum function.
Return Values
ERROR_SUCCESS indicates success. An error value indicates failure. To get extended error information, call GetLastError. Possible GetLastError values are described in the following table.
Value | Description |
ERROR_NO_NETWORK | A network is not present. |
ERROR_INVALID_HANDLE | The handle specified in hEnum is not valid. |
The function returns error values for compatibility with Windows for Workgroups. For compatibility with Win32, the function also sets the error value returned by GetLastError.