WaitHandleCannotBeOpenedException WaitHandleCannotBeOpenedException WaitHandleCannotBeOpenedException WaitHandleCannotBeOpenedException Constructors

Definition

Overloads

WaitHandleCannotBeOpenedException() WaitHandleCannotBeOpenedException() WaitHandleCannotBeOpenedException()

Initializes a new instance of the WaitHandleCannotBeOpenedException class with default values.

WaitHandleCannotBeOpenedException(String) WaitHandleCannotBeOpenedException(String) WaitHandleCannotBeOpenedException(String) WaitHandleCannotBeOpenedException(String)

Initializes a new instance of the WaitHandleCannotBeOpenedException class with a specified error message.

WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext) WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext) WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext) WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext)

Initializes a new instance of the WaitHandleCannotBeOpenedException class with serialized data.

WaitHandleCannotBeOpenedException(String, Exception) WaitHandleCannotBeOpenedException(String, Exception) WaitHandleCannotBeOpenedException(String, Exception) WaitHandleCannotBeOpenedException(String, Exception)

Initializes a new instance of the WaitHandleCannotBeOpenedException class with a specified error message and a reference to the inner exception that is the cause of this exception.

WaitHandleCannotBeOpenedException() WaitHandleCannotBeOpenedException() WaitHandleCannotBeOpenedException()

Initializes a new instance of the WaitHandleCannotBeOpenedException class with default values.

public:
 WaitHandleCannotBeOpenedException();
public WaitHandleCannotBeOpenedException ();
Public Sub New ()

Remarks

This constructor initializes the Message property of the new instance to a system-supplied message that describes the error, such as "No handle of the given name exists." This message takes into account the current system culture.

The following table shows the initial property values for an instance of WaitHandleCannotBeOpenedException.

Property Value
InnerException null.
Message The system-supplied error message string.

WaitHandleCannotBeOpenedException(String) WaitHandleCannotBeOpenedException(String) WaitHandleCannotBeOpenedException(String) WaitHandleCannotBeOpenedException(String)

Initializes a new instance of the WaitHandleCannotBeOpenedException class with a specified error message.

public:
 WaitHandleCannotBeOpenedException(System::String ^ message);
public WaitHandleCannotBeOpenedException (string message);
new System.Threading.WaitHandleCannotBeOpenedException : string -> System.Threading.WaitHandleCannotBeOpenedException
Public Sub New (message As String)

Parameters

message
String String String String

The error message that explains the reason for the exception.

Remarks

The content of message is intended to be understood by humans. The caller of this constructor is required to ensure that this string has been localized for the current system culture.

The following table shows the initial property values for an instance of WaitHandleCannotBeOpenedException initialized with this constructor.

Property Value
InnerException null.
Message message.

WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext) WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext) WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext) WaitHandleCannotBeOpenedException(SerializationInfo, StreamingContext)

Initializes a new instance of the WaitHandleCannotBeOpenedException class with serialized data.

protected:
 WaitHandleCannotBeOpenedException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected WaitHandleCannotBeOpenedException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.Threading.WaitHandleCannotBeOpenedException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Threading.WaitHandleCannotBeOpenedException
Protected Sub New (info As SerializationInfo, context As StreamingContext)

Parameters

info
SerializationInfo SerializationInfo SerializationInfo SerializationInfo

The SerializationInfo object that holds the serialized object data about the exception being thrown.

context
StreamingContext StreamingContext StreamingContext StreamingContext

The StreamingContext object that contains contextual information about the source or destination.

Remarks

This constructor is called during deserialization to reconstitute the exception object transmitted over a stream. For more information, see XML and SOAP Serialization.

WaitHandleCannotBeOpenedException(String, Exception) WaitHandleCannotBeOpenedException(String, Exception) WaitHandleCannotBeOpenedException(String, Exception) WaitHandleCannotBeOpenedException(String, Exception)

Initializes a new instance of the WaitHandleCannotBeOpenedException class with a specified error message and a reference to the inner exception that is the cause of this exception.

public:
 WaitHandleCannotBeOpenedException(System::String ^ message, Exception ^ innerException);
public WaitHandleCannotBeOpenedException (string message, Exception innerException);
new System.Threading.WaitHandleCannotBeOpenedException : string * Exception -> System.Threading.WaitHandleCannotBeOpenedException
Public Sub New (message As String, innerException As Exception)

Parameters

message
String String String String

The error message that explains the reason for the exception.

innerException
Exception Exception Exception Exception

The exception that is the cause of the current exception. If the innerException parameter is not null, the current exception is raised in a catch block that handles the inner exception.

Remarks

An exception that is thrown as a direct result of a previous exception should include a reference to the previous exception in the InnerException property. The InnerException property returns the same value that is passed into the constructor, or null if the InnerException property does not supply the inner exception value to the constructor.

Applies to