Dispatcher.ValidatePriority Method

Determines whether the specified DispatcherPriority is a valid priority.

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

public static void ValidatePriority(
	DispatcherPriority priority,
	string parameterName
)

Parameters

priority
Type: System.Windows.Threading.DispatcherPriority

The priority to check.

parameterName
Type: System.String

A string that will be returned by the exception that occurs if the priority is invalid.

ExceptionCondition
InvalidEnumArgumentException

priority is not a valid DispatcherPriority.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2015 Microsoft