Dispatcher.FromThread Method

Gets the Dispatcher for the specified thread.

Namespace: System.Windows.Threading
Assembly: WindowsBase (in windowsbase.dll)

public static Dispatcher FromThread (
	Thread thread
)
public static Dispatcher FromThread (
	Thread thread
)
public static function FromThread (
	thread : Thread
) : Dispatcher
You cannot use methods in XAML.

Parameters

thread

The thread to obtain the Dispatcher from.

Return Value

The dispatcher for thread.

If a dispatcher is not available for the specified thread, a null reference (Nothing in Visual Basic) will be returned.

FromThread does not create a Dispatcher on a thread which does not have a Dispatcher. A new Dispatcher is created on a thread which does not already have a Dispatcher when attempting to get the Dispatcher by using the CurrentDispatcher property.

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, 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

Community Additions

ADD
Show: