Export (0) Print
Expand All

SynchronizationContext::SetThreadStaticContext Method

.NET Framework 4.5

Sets the current context for thread static data.

Namespace:  System.Threading
Assembly:  mscorlib (in mscorlib.dll)

public:
static void SetThreadStaticContext(
	SynchronizationContext^ syncContext
)

Parameters

syncContext
Type: System.Threading::SynchronizationContext

The context that is to be set.

ExceptionCondition
MethodAccessException

The property is security-critical but is accessed from transparent code.

Important noteImportant

Do not use this member in an app that targets Windows Phone OS 7.0 or 7.1. If you do, your code will throw a MethodAccessException. This member is security-critical, which restricts it to internal use only by the .NET Framework for Windows Phone class library.

Supported in: Windows Phone 8.1

Supported in: Windows Phone Silverlight 8.1

Supported in: Windows Phone Silverlight 8

Windows Phone 8.1, Windows Phone 8

Show:
© 2014 Microsoft