CancelConnectAsync Method

Socket.CancelConnectAsync Method

[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]

Cancels an outstanding asynchronous socket operation for a remote host connection.

Namespace:  System.Net.Sockets
Assembly:  System.Net (in System.Net.dll)

public static void CancelConnectAsync(
	SocketAsyncEventArgs e
)

Parameters

e
Type: System.Net.Sockets.SocketAsyncEventArgs
The System.Net.Sockets.SocketAsyncEventArgs object for the asynchronous socket operation that should be canceled.

ExceptionCondition
ArgumentNullException

The e parameter is null.

The CancelConnectAsync(SocketAsyncEventArgs) method cancels an asynchronous request for a remote host connection.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1

Windows Phone

Show:
© 2017 Microsoft