InvalidComObjectException Constructeurs
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Initialise une instance de la InvalidComObjectException classe.
Surcharges
| Nom | Description |
|---|---|
| InvalidComObjectException() |
Initialise une instance des |
| InvalidComObjectException(String) |
Initialise une instance du |
| InvalidComObjectException(SerializationInfo, StreamingContext) |
Obsolète.
Initialise une nouvelle instance de la |
| InvalidComObjectException(String, Exception) |
Initialise une nouvelle instance de la InvalidComObjectException classe avec un message d’erreur spécifié et une référence à l’exception interne qui est la cause de cette exception. |
InvalidComObjectException()
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
Initialise une instance des InvalidComObjectException propriétés par défaut.
public:
InvalidComObjectException();
public InvalidComObjectException();
Public Sub New ()
Remarques
InvalidComObjectException hérite de SystemException. Ce constructeur définit les propriétés de l’objet Exception , comme indiqué dans le tableau suivant.
| Type de propriété | Valeur |
|---|---|
| InnerException |
null. |
| Message | Chaîne de message d’erreur localisée. |
S’applique à
InvalidComObjectException(String)
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
Initialise une instance du InvalidComObjectException message.
public:
InvalidComObjectException(System::String ^ message);
public InvalidComObjectException(string message);
public InvalidComObjectException(string? message);
new System.Runtime.InteropServices.InvalidComObjectException : string -> System.Runtime.InteropServices.InvalidComObjectException
Public Sub New (message As String)
Paramètres
- message
- String
Message qui indique la raison de l’exception.
Remarques
InvalidComObjectException hérite de SystemException. Ce constructeur définit les propriétés de l’objet Exception , comme indiqué dans le tableau suivant.
| Type de propriété | Valeur |
|---|---|
| InnerException |
null. |
| Message | message |
S’applique à
InvalidComObjectException(SerializationInfo, StreamingContext)
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
Attention
This API supports obsolete formatter-based serialization. It should not be called or extended by application code.
Initialise une nouvelle instance de la COMException classe à partir de données de sérialisation.
protected:
InvalidComObjectException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
[System.Obsolete("This API supports obsolete formatter-based serialization. It should not be called or extended by application code.", DiagnosticId="SYSLIB0051", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
protected InvalidComObjectException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
protected InvalidComObjectException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
[<System.Obsolete("This API supports obsolete formatter-based serialization. It should not be called or extended by application code.", DiagnosticId="SYSLIB0051", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
new System.Runtime.InteropServices.InvalidComObjectException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Runtime.InteropServices.InvalidComObjectException
new System.Runtime.InteropServices.InvalidComObjectException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Runtime.InteropServices.InvalidComObjectException
Protected Sub New (info As SerializationInfo, context As StreamingContext)
Paramètres
- info
- SerializationInfo
Objet qui contient les données d’objet sérialisées.
- context
- StreamingContext
Informations contextuelles sur la source ou la destination.
- Attributs
Exceptions
info a la valeur null.
Remarques
Ce constructeur est appelé lors de la désérialisation pour rétablir l’objet d’exception transmis sur un flux. Pour plus d’informations, consultez System.Runtime.Serialization.
InvalidComObjectException hérite de SystemException.
S’applique à
InvalidComObjectException(String, Exception)
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
- Source:
- InvalidComObjectException.cs
Initialise une nouvelle instance de la InvalidComObjectException classe avec un message d’erreur spécifié et une référence à l’exception interne qui est la cause de cette exception.
public:
InvalidComObjectException(System::String ^ message, Exception ^ inner);
public InvalidComObjectException(string message, Exception inner);
public InvalidComObjectException(string? message, Exception? inner);
new System.Runtime.InteropServices.InvalidComObjectException : string * Exception -> System.Runtime.InteropServices.InvalidComObjectException
Public Sub New (message As String, inner As Exception)
Paramètres
- message
- String
Message d’erreur qui explique la raison de l’exception.
- inner
- Exception
Exception qui est la cause de l’exception actuelle. Si le inner paramètre n’est pas null, l’exception actuelle est levée dans un catch bloc qui gère l’exception interne.
Remarques
Une exception levée en conséquence directe d’une exception précédente doit inclure une référence à l’exception précédente dans la InnerException propriété. La InnerException propriété retourne la même valeur que celle passée dans le constructeur, ou null si la InnerException propriété ne fournit pas la valeur d’exception interne au constructeur.
Le tableau suivant présente les valeurs de propriété initiales d’une instance de InvalidComObjectException.
| Propriété | Valeur |
|---|---|
| InnerException | Référence d’exception interne. |
| Message | Chaîne de message d’erreur. |