Multithreading in Windows Forms Controls

In many applications, you can make your user interface (UI) more responsive by performing time-consuming operations on another thread. A number of tools are available for multithreading your Windows Forms controls, including the System.Threading namespace, the Control.BeginInvoke method, and the BackgroundWorker component.

Note

The BackgroundWorker component replaces and adds functionality to the System.Threading namespace and the Control.BeginInvoke method; however, these are retained for both backward compatibility and future use, if you choose. For more information, see BackgroundWorker Component Overview.

In This Section

How to: Make Thread-Safe Calls to Windows Forms Controls
Shows how to make thread-safe calls to Windows Forms controls.

How to: Use a Background Thread to Search for Files
Shows how to use the System.Threading namespace and the BeginInvoke method to search for files asynchronously.

Reference

BackgroundWorker
Documents a component that encapsulates a worker thread for asynchronous operations.

LoadAsync
Documents how to load a sound asynchronously.

LoadAsync
Documents how to load an image asynchronously.

How to: Run an Operation in the Background
Shows how to perform a time-consuming operation with the BackgroundWorker component.

BackgroundWorker Component Overview
Provides topics that describe how to use the BackgroundWorker component for asynchronous operations.