System.Net.Sockets.SocketAsyncEventArgs.Completed Event

The event used to complete an asynchronous operation.

Syntax

public event EventHandler<SocketAsyncEventArgs> Completed

Remarks

The SocketAsyncEventArgs.Completed event provides a way for client applications to complete an asynchronous socket operation. An event handler should be attached to the event within a System.Net.Sockets.SocketAsyncEventArgs instance when an asynchronous socket operation is initiated, otherwise the application will not be able to determine when the operation completes.

The completion callback delegates referenced by the SocketAsyncEventArgs.Completed event contains program logic to finish processing the asynchronous socket operation for the client.

When the event is signaled, the application uses the System.Net.Sockets.SocketAsyncEventArgs object parameter to obtain the status of the completed asynchronous socket operation.

Requirements

Namespace: System.Net.Sockets
Assembly: System (in System.dll)
Assembly Versions: 2.0.0.0, 4.0.0.0