BackgroundWorker.ProgressChanged Event

Occurs when ReportProgress is called.

Namespace: System.ComponentModel
Assembly: System (in system.dll)

public event ProgressChangedEventHandler ProgressChanged
/** @event */
public void add_ProgressChanged (ProgressChangedEventHandler value)

/** @event */
public void remove_ProgressChanged (ProgressChangedEventHandler value)

In JScript, you can handle the events defined by a class, but you cannot define your own.
Not applicable.

This event is raised when you call the ReportProgress method.

For more information about handling events, see Consuming Events.

The following code example demonstrates the use of the ProgressChanged event to report the progress of an asynchronous operation to the user. This code example is part of a larger example provided for the BackgroundWorker class.

// This event handler updates the progress bar.
private void backgroundWorker1_ProgressChanged(object sender,
    ProgressChangedEventArgs e)
    this.progressBar1.Value = e.ProgressPercentage;

// This event handler updates the progress bar.
private void backgroundWorker1_ProgressChanged(Object sender,
    ProgressChangedEventArgs e)
} //backgroundWorker1_ProgressChanged

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0