WNetDisconnectDialog1 (Windows CE 5.0)
This function attempts to disconnect from a network. If the underlying network returns ERROR_OPEN_FILES, the function prompts the user for confirmation. Users will be informed of any errors.
DWORDWNetDisconnectDialog1(LPDISCDLGSTRUCTlpDiscDlgStruct );
Parameters
- lpDiscDlgStruct
[in] Long pointer to the DISCDLGSTRUCT data structure, which specifies the behavior for the disconnect attempt.
Return Values
ERROR_SUCCESS indicates success. An error value indicates failure. To get extended error information, call GetLastError. Possible GetLastError error values are described in the following table.
Value | Description |
---|---|
ERROR_SUCCESS | The connection is successfully disconnected. |
ERROR_CANCELLED | After the user was prompted for a decision to disconnect, the user elected not to disconnect. |
ERROR_OPEN_FILES | The function is unable to disconnect because the user is actively using the connection. |
ERROR_BUSY | The network provider is busy, and is possibly initializing. The caller should retry. |
ERROR_NO_NETWORK | The network is not present. |
ERROR_NOT_ENOUGH_MEMORY | There is insufficient memory to start the dialog box. |
Requirements
OS Versions: Windows CE 2.0 and later.
Header: Winnetwk.h.
Link Library: Coredll.lib.
See Also
Send Feedback on this topic to the authors