System.DuplicateWaitObjectException Class

The exception that is thrown when an object appears more than once in an array of synchronization objects.

See Also: DuplicateWaitObjectException Members

Syntax

[System.Runtime.InteropServices.ComVisible(true)]
public class DuplicateWaitObjectException : ArgumentException

Remarks

The common language runtime provides a thread synchronization mechanism based on synchronization objects waiting for execution in an array of System.Threading.WaitHandle objects. If the array of System.Threading.WaitHandle objects passed to System.Threading.WaitHandle.WaitAll(System.Threading.WaitHandle[], int, bool) or System.Threading.WaitHandle.WaitAny(System.Threading.WaitHandle[], int, bool) contains any duplicate operating system handles, DuplicateWaitObjectException is thrown. For more information, see System.Threading.WaitHandle.

DuplicateWaitObjectException uses the HRESULT COR_E_DUPLICATEWAITOBJECT, which has the value 0x80131529.

For a list of initial property values for an instance of DuplicateWaitObjectException, see the DuplicateWaitObjectException.#ctor constructors.

Note:

This exception is not included in the tp://go.microsoft.com/fwlink/?LinkID=247912 or the Portable Class Library, but it is thrown by some members that are. To catch the exception in that case, write a catch statement for ArgumentException instead.

Thread Safety

All public static members of this type are safe for multithreaded operations. No instance members are guaranteed to be thread safe.

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0