AsyncCompletedEventArgs Constructors

Definition

Initializes a new instance of the AsyncCompletedEventArgs class.

Overloads

AsyncCompletedEventArgs()
Obsolete.

Initializes a new instance of the AsyncCompletedEventArgs class.

AsyncCompletedEventArgs(Exception, Boolean, Object)

Initializes a new instance of the AsyncCompletedEventArgs class.

AsyncCompletedEventArgs()

Caution

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

Initializes a new instance of the AsyncCompletedEventArgs class.

C#
[System.Obsolete("This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.", true)]
public AsyncCompletedEventArgs();
Attributes

Applies to

.NET Framework 4.8.1 and other versions
Product Versions (Obsolete)
.NET Framework (4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1)

AsyncCompletedEventArgs(Exception, Boolean, Object)

Source:
AsyncCompletedEvent.cs
Source:
AsyncCompletedEvent.cs
Source:
AsyncCompletedEvent.cs

Initializes a new instance of the AsyncCompletedEventArgs class.

C#
public AsyncCompletedEventArgs(Exception error, bool cancelled, object userState);
C#
public AsyncCompletedEventArgs(Exception? error, bool cancelled, object? userState);

Parameters

error
Exception

Any error that occurred during the asynchronous operation.

cancelled
Boolean

A value indicating whether the asynchronous operation was canceled.

userState
Object

The optional user-supplied state object passed to the RunWorkerAsync(Object) method.

Applies to

.NET 9 and other versions
Product Versions
.NET Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1
UWP 10.0