TargetException Constructor ()

 

Initializes a new instance of the TargetException class with an empty message and the root cause of the exception.

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

public TargetException()

The InnerException property is set to null and the HRESULT error code is set to COR_E_TARGET.

TargetException inherits from the Exception. This constructor sets the properties of the Exception object as shown in the following table.

Property

Value

InnerException

null

Message

The empty string ("").

.NET Framework
Available since 1.1
Return to top
Show: