BadImageFormatException コンストラクター

定義

BadImageFormatException クラスの新しいインスタンスを初期化します。

オーバーロード

BadImageFormatException()

BadImageFormatException クラスの新しいインスタンスを初期化します。

BadImageFormatException(String)

指定したエラー メッセージを使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

BadImageFormatException(SerializationInfo, StreamingContext)
古い.

シリアル化したデータを使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

BadImageFormatException(String, Exception)

指定したエラー メッセージおよびこの例外の原因となった内部例外への参照を使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

BadImageFormatException(String, String)

指定したエラー メッセージとファイル名を使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

BadImageFormatException(String, String, Exception)

指定したエラー メッセージおよびこの例外の原因となった内部例外への参照を使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

BadImageFormatException()

Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs

BadImageFormatException クラスの新しいインスタンスを初期化します。

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

注釈

このコンストラクターは、"実行可能ファイルまたはライブラリの形式が無効です" などのエラーを説明するシステム指定のメッセージに対して、新しいインスタンスの プロパティを初期化 Message します。このメッセージでは、現在のシステム カルチャが考慮されます。

次の表に、BadImageFormatException のインスタンスに対するプロパティの初期値を示します。

プロパティ
InnerException null 参照 (Visual Basic の場合は Nothing)。
Message ローカライズされたエラー メッセージ文字列。

適用対象

BadImageFormatException(String)

Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs

指定したエラー メッセージを使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

public:
 BadImageFormatException(System::String ^ message);
public BadImageFormatException (string message);
public BadImageFormatException (string? message);
new BadImageFormatException : string -> BadImageFormatException
Public Sub New (message As String)

パラメーター

message
String

エラーを説明するメッセージ。

注釈

message パラメーターの内容は、ユーザーが理解できる内容にします。 このコンストラクターの呼び出し元は、この文字列が現在のシステム環境向けにローカライズされていることを確認する必要があります。

次の表に、BadImageFormatException のインスタンスに対するプロパティの初期値を示します。

プロパティ
InnerException null 参照 (Visual Basic の場合は Nothing)。
Message エラー メッセージ文字列。

適用対象

BadImageFormatException(SerializationInfo, StreamingContext)

Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs

注意事項

This API supports obsolete formatter-based serialization. It should not be called or extended by application code.

シリアル化したデータを使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

protected:
 BadImageFormatException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected BadImageFormatException (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 BadImageFormatException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new BadImageFormatException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> BadImageFormatException
[<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 BadImageFormatException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> BadImageFormatException
Protected Sub New (info As SerializationInfo, context As StreamingContext)

パラメーター

info
SerializationInfo

スローされている例外に関するシリアル化済みオブジェクト データを保持している SerializationInfo

context
StreamingContext

転送元または転送先についてのコンテキスト情報を含む StreamingContext です。

属性

注釈

このコンストラクターは、シリアル化解除の際に呼び出されて、ストリームで送信された例外オブジェクトを再構成します。

適用対象

BadImageFormatException(String, Exception)

Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs

指定したエラー メッセージおよびこの例外の原因となった内部例外への参照を使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

public:
 BadImageFormatException(System::String ^ message, Exception ^ inner);
public BadImageFormatException (string message, Exception inner);
public BadImageFormatException (string? message, Exception? inner);
new BadImageFormatException : string * Exception -> BadImageFormatException
Public Sub New (message As String, inner As Exception)

パラメーター

message
String

例外の原因を説明するエラー メッセージ。

inner
Exception

現在の例外の原因となった例外。 inner パラメーターが null 参照でない場合は、内部例外を処理する catch ブロックで現在の例外が発生します。

注釈

前の例外の直接の結果としてスローされる例外については、InnerException プロパティに、前の例外への参照を含める必要があります。 InnerException プロパティは、コンストラクターに渡されるのと同じ値を返します。または、InnerException プロパティがコンストラクターに内部例外値を提供しない場合には null を返します。

次の表に、BadImageFormatException のインスタンスに対するプロパティの初期値を示します。

プロパティ [値]
InnerException 内部例外の参照。
Message エラー メッセージ文字列。

こちらもご覧ください

適用対象

BadImageFormatException(String, String)

Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs

指定したエラー メッセージとファイル名を使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

public:
 BadImageFormatException(System::String ^ message, System::String ^ fileName);
public BadImageFormatException (string message, string fileName);
public BadImageFormatException (string? message, string? fileName);
new BadImageFormatException : string * string -> BadImageFormatException
Public Sub New (message As String, fileName As String)

パラメーター

message
String

エラーについて説明するメッセージ。

fileName
String

無効なイメージを含んでいるファイルの完全名。

注釈

message パラメーターの内容は、ユーザーが理解できる内容にします。 このコンストラクターの呼び出し元は、この文字列が現在のシステム環境向けにローカライズされていることを確認する必要があります。

プロパティ
FileName 無効なイメージを含んでいるファイルの完全名。
Message エラー メッセージ文字列。

適用対象

BadImageFormatException(String, String, Exception)

Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs
Source:
BadImageFormatException.cs

指定したエラー メッセージおよびこの例外の原因となった内部例外への参照を使用して、BadImageFormatException クラスの新しいインスタンスを初期化します。

public:
 BadImageFormatException(System::String ^ message, System::String ^ fileName, Exception ^ inner);
public BadImageFormatException (string message, string fileName, Exception inner);
public BadImageFormatException (string? message, string? fileName, Exception? inner);
new BadImageFormatException : string * string * Exception -> BadImageFormatException
Public Sub New (message As String, fileName As String, inner As Exception)

パラメーター

message
String

例外の原因を説明するエラー メッセージ。

fileName
String

無効なイメージを含んでいるファイルの完全名。

inner
Exception

現在の例外の原因となった例外。 inner パラメーターが null でない場合は、内部例外を処理する catch ブロックで現在の例外が発生します。

注釈

前の例外の直接の結果としてスローされる例外については、InnerException プロパティに、前の例外への参照を含める必要があります。 InnerException プロパティは、コンストラクターに渡されるのと同じ値を返します。または、InnerException プロパティがコンストラクターに内部例外値を提供しない場合には null を返します。

次の表に、BadImageFormatException のインスタンスに対するプロパティの初期値を示します。

プロパティ [値]
InnerException 内部例外の参照。
FileName 無効なイメージを含んでいるファイルの完全名。
Message エラー メッセージ文字列。

適用対象