TargetInvocationException Clase
Definición
Excepción que se produce en los métodos llamados mediante reflexión.The exception that is thrown by methods invoked through reflection. Esta clase no puede heredarse.This class cannot be inherited.
public ref class TargetInvocationException sealed : Exception
public ref class TargetInvocationException sealed : ApplicationException
public sealed class TargetInvocationException : Exception
public sealed class TargetInvocationException : ApplicationException
[System.Serializable]
public sealed class TargetInvocationException : ApplicationException
[System.Serializable]
[System.Runtime.InteropServices.ComVisible(true)]
public sealed class TargetInvocationException : ApplicationException
type TargetInvocationException = class
inherit Exception
type TargetInvocationException = class
inherit ApplicationException
[<System.Serializable>]
type TargetInvocationException = class
inherit ApplicationException
[<System.Serializable>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type TargetInvocationException = class
inherit ApplicationException
Public NotInheritable Class TargetInvocationException
Inherits Exception
Public NotInheritable Class TargetInvocationException
Inherits ApplicationException
- Herencia
- Herencia
- Atributos
Comentarios
Para obtener más información, vea Invoke.For more information, see Invoke.
TargetInvocationException
utiliza el COR_E_TARGETINVOCATION HRESULT que tiene el valor 0x80131604.TargetInvocationException
uses the HRESULT COR_E_TARGETINVOCATION which has the value 0x80131604.
Cuando se crea, TargetInvocationException
se pasa una referencia a la excepción producida por el método invocado mediante reflexión.When created, the TargetInvocationException
is passed a reference to the exception thrown by the method invoked through reflection. La InnerException propiedad contiene la excepción subyacente.The InnerException property holds the underlying exception.
Constructores
TargetInvocationException(Exception) |
Inicializa una nueva instancia de la clase TargetInvocationException con una referencia a la excepción interna que representa la causa de esta excepción.Initializes a new instance of the TargetInvocationException class with a reference to the inner exception that is the cause of this exception. |
TargetInvocationException(String, Exception) |
Inicializa una nueva instancia de la clase TargetInvocationException con el mensaje de error especificado y una referencia a la excepción interna que representa la causa de esta excepción.Initializes a new instance of the TargetInvocationException class with a specified error message and a reference to the inner exception that is the cause of this exception. |
Propiedades
Data |
Obtiene una colección de pares clave/valor que proporciona información definida por el usuario adicional sobre la excepción.Gets a collection of key/value pairs that provide additional user-defined information about the exception. (Heredado de Exception) |
HelpLink |
Obtiene o establece un vínculo al archivo de ayuda asociado a esta excepción.Gets or sets a link to the help file associated with this exception. (Heredado de Exception) |
HResult |
Obtiene o establece HRESULT, un valor numérico codificado que se asigna a una excepción específica.Gets or sets HRESULT, a coded numerical value that is assigned to a specific exception. (Heredado de Exception) |
InnerException |
Obtiene la instancia Exception que produjo la excepción actual.Gets the Exception instance that caused the current exception. (Heredado de Exception) |
Message |
Obtiene un mensaje que describe la excepción actual.Gets a message that describes the current exception. (Heredado de Exception) |
Source |
Devuelve o establece el nombre de la aplicación o del objeto que generó el error.Gets or sets the name of the application or the object that causes the error. (Heredado de Exception) |
StackTrace |
Obtiene una representación de cadena de los marcos inmediatos en la pila de llamadas.Gets a string representation of the immediate frames on the call stack. (Heredado de Exception) |
TargetSite |
Obtiene el método que produjo la excepción actual.Gets the method that throws the current exception. (Heredado de Exception) |
Métodos
Equals(Object) |
Determina si el objeto especificado es igual que el objeto actual.Determines whether the specified object is equal to the current object. (Heredado de Object) |
GetBaseException() |
Cuando se invalida en una clase derivada, devuelve la clase Exception que representa la causa principal de una o más excepciones posteriores.When overridden in a derived class, returns the Exception that is the root cause of one or more subsequent exceptions. (Heredado de Exception) |
GetHashCode() |
Sirve como la función hash predeterminada.Serves as the default hash function. (Heredado de Object) |
GetObjectData(SerializationInfo, StreamingContext) |
Cuando se invalida en una clase derivada, establece SerializationInfo con información sobre la excepción.When overridden in a derived class, sets the SerializationInfo with information about the exception. (Heredado de Exception) |
GetType() |
Obtiene el tipo de tiempo de ejecución de la instancia actual.Gets the runtime type of the current instance. (Heredado de Exception) |
MemberwiseClone() |
Crea una copia superficial del Object actual.Creates a shallow copy of the current Object. (Heredado de Object) |
ToString() |
Crea y devuelve una representación de cadena de la excepción actual.Creates and returns a string representation of the current exception. (Heredado de Exception) |
Eventos
SerializeObjectState |
Ocurre cuando una excepción se serializa para crear un objeto de estado de excepción que contenga datos serializados sobre la excepción.Occurs when an exception is serialized to create an exception state object that contains serialized data about the exception. (Heredado de Exception) |