MethodException Constructor

 

Updated: April 27, 2016

Applies To: Windows PowerShell

Creates a new MethodException object. The variants of this constructor can be used to create an empty object, an object that contains an exception message, and more.

Namespace:   System.Management.Automation
Assembly:  System.Management.Automation (in System.Management.Automation.dll)

NameDescription
System_CAPS_pubmethodMethodException()

Creates a new MethodException object that is empty.

System_CAPS_protmethodMethodException(SerializationInfo, StreamingContext)

Creates a new MethodException object that contains information read from the provided serialization information.

System_CAPS_pubmethodMethodException(String)

Creates a new MethodException object that contains an exception message.

System_CAPS_pubmethodMethodException(String, Exception)

Creates a new MethodException object that contains an exception message and the inner exception that caused this exception to be thrown.

For more information about the different types of methods used within the extended type system, see ETS Methods [ps].

Return to top

Community Additions

ADD
Show: