Export (0) Print
Expand All
1 out of 2 rated this helpful - Rate this topic

SocketError Enumeration

Defines error codes for the Socket class.

Namespace:  System.Net.Sockets
Assembly:  System.Net (in System.Net.dll)
public enum SocketError
Member nameDescription
Supported by Silverlight for Windows PhoneSuccessThe Socket operation succeeded.
Supported by Silverlight for Windows PhoneSocketErrorAn unspecified Socket error has occurred.
Supported by Silverlight for Windows PhoneInterruptedA blocking Socket call was canceled.
Supported by Silverlight for Windows PhoneAccessDeniedAn attempt was made to access a Socket in a way that is forbidden by its access permissions.
Supported by Silverlight for Windows PhoneFaultAn invalid pointer address was detected by the underlying socket provider.
Supported by Silverlight for Windows PhoneInvalidArgumentAn invalid argument was supplied to a Socket member.
Supported by Silverlight for Windows PhoneTooManyOpenSocketsThere are too many open sockets in the underlying socket provider.
Supported by Silverlight for Windows PhoneWouldBlockAn operation on a nonblocking socket cannot be completed immediately.
Supported by Silverlight for Windows PhoneInProgressA blocking operation is in progress.
Supported by Silverlight for Windows PhoneAlreadyInProgressThe nonblocking Socket already has an operation in progress.
Supported by Silverlight for Windows PhoneNotSocketA Socket operation was attempted on a non-socket.
Supported by Silverlight for Windows PhoneDestinationAddressRequiredA required address was omitted from an operation on a Socket.
Supported by Silverlight for Windows PhoneMessageSizeThe datagram is too long.
Supported by Silverlight for Windows PhoneProtocolTypeThe protocol type is incorrect for this Socket.
Supported by Silverlight for Windows PhoneProtocolOptionAn unknown, invalid, or unsupported option or level was used with a Socket.
Supported by Silverlight for Windows PhoneProtocolNotSupportedThe protocol is not implemented or has not been configured.
Supported by Silverlight for Windows PhoneSocketNotSupportedThe support for the specified socket type does not exist in this address family.
Supported by Silverlight for Windows PhoneOperationNotSupportedThe address family is not supported by the protocol family.
Supported by Silverlight for Windows PhoneProtocolFamilyNotSupportedThe protocol family is not implemented or has not been configured.
Supported by Silverlight for Windows PhoneAddressFamilyNotSupportedThe address family specified is not supported. This error is returned if the IPv6 address family was specified and the IPv6 stack is not installed on the local machine. This error is returned if the IPv4 address family was specified and the IPv4 stack is not installed on the local machine.
Supported by Silverlight for Windows PhoneAddressAlreadyInUseOnly one use of an address is normally permitted.
Supported by Silverlight for Windows PhoneAddressNotAvailableThe selected IP address is not valid in this context.
Supported by Silverlight for Windows PhoneNetworkDownThe network is not available.
Supported by Silverlight for Windows PhoneNetworkUnreachableNo route to the remote host exists.
Supported by Silverlight for Windows PhoneNetworkResetThe application tried to set an option on a connection that has already timed out.
Supported by Silverlight for Windows PhoneConnectionAbortedThe connection was aborted by the .NET Framework or the underlying socket provider.
Supported by Silverlight for Windows PhoneConnectionResetThe connection was reset by the remote peer.
Supported by Silverlight for Windows PhoneNoBufferSpaceAvailableNo free buffer space is available for a Socket operation.
Supported by Silverlight for Windows PhoneIsConnectedThe Socket is already connected.
Supported by Silverlight for Windows PhoneNotConnectedThe application tried to send or receive data, and the Socket is not connected.
Supported by Silverlight for Windows PhoneShutdownA request to send or receive data was disallowed because the Socket has already been closed.
Supported by Silverlight for Windows PhoneTimedOutThe connection attempt timed out, or the connected host has failed to respond.
Supported by Silverlight for Windows PhoneConnectionRefusedThe remote host is actively refusing a connection.
Supported by Silverlight for Windows PhoneHostDownThe operation failed because the remote host is down.
Supported by Silverlight for Windows PhoneHostUnreachableThere is no network route to the specified host.
Supported by Silverlight for Windows PhoneProcessLimitToo many processes are using the underlying socket provider.
Supported by Silverlight for Windows PhoneSystemNotReadyThe network subsystem is unavailable.
Supported by Silverlight for Windows PhoneVersionNotSupportedThe version of the underlying socket provider is out of range.
Supported by Silverlight for Windows PhoneNotInitializedThe underlying socket provider has not been initialized.
Supported by Silverlight for Windows PhoneDisconnectingA graceful shutdown is in progress.
Supported by Silverlight for Windows PhoneTypeNotFoundThe specified class was not found.
Supported by Silverlight for Windows PhoneHostNotFoundNo such host is known. The name is not an official host name or alias.
Supported by Silverlight for Windows PhoneTryAgainThe name of the host could not be resolved. Try again later.
Supported by Silverlight for Windows PhoneNoRecoveryThe error is unrecoverable or the requested database cannot be located.
Supported by Silverlight for Windows PhoneNoDataThe requested name or IP address was not found on the name server.
Supported by Silverlight for Windows PhoneIOPendingThe application has initiated an overlapped operation that cannot be completed immediately.
Supported by Silverlight for Windows PhoneOperationAbortedThe overlapped operation was aborted due to the closure of the Socket.

Most of these errors are returned by the underlying socket provider.

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.