XmlExceptionとは? わかりやすく解説

XmlException クラス

最後の例外に関する詳細情報を返します。

名前空間: System.Xml
アセンブリ: System.Xml (system.xml.dll 内)
構文構文

<SerializableAttribute> _
Public Class XmlException
    Inherits SystemException
[SerializableAttribute] 
public class XmlException : SystemException
[SerializableAttribute] 
public ref class XmlException : public
 SystemException
/** @attribute SerializableAttribute() */ 
public class XmlException extends SystemException
SerializableAttribute 
public class XmlException extends
 SystemException
継承階層継承階層
System.Object
   System.Exception
     System.SystemException
      System.Xml.XmlException
スレッド セーフスレッド セーフ
この型の public static (Visual Basic では Shared) メンバはすべて、スレッド セーフです。インスタンス メンバの場合は、スレッド セーフであるとは限りません。
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

XmlException コンストラクタ ()


XmlException コンストラクタ (String, Exception)

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

名前空間: System.Xml
アセンブリ: System.Xml (system.xml.dll 内)
構文構文

Public Sub New ( _
    message As String, _
    innerException As Exception _
)
Dim message As String
Dim innerException As Exception

Dim instance As New XmlException(message,
 innerException)
public XmlException (
    string message,
    Exception innerException
)
public:
XmlException (
    String^ message, 
    Exception^ innerException
)
public XmlException (
    String message, 
    Exception innerException
)
public function XmlException (
    message : String, 
    innerException : Exception
)

パラメータ

message

エラー状態の説明。

innerException

XmlException をスローした Exception (存在する場合)。この値は、null 参照 (Visual Basic では Nothing) の場合もあります。

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

XmlException コンストラクタ (String)


XmlException コンストラクタ (SerializationInfo, StreamingContext)

SerializationInfo オブジェクトおよび StreamingContext オブジェクトの情報を使用して、XmlException クラスの新しいインスタンスを初期化します。

名前空間: System.Xml
アセンブリ: System.Xml (system.xml.dll 内)
構文構文

Protected Sub New ( _
    info As SerializationInfo, _
    context As StreamingContext _
)
Dim info As SerializationInfo
Dim context As StreamingContext

Dim instance As New XmlException(info,
 context)
protected XmlException (
    SerializationInfo info,
    StreamingContext context
)
protected:
XmlException (
    SerializationInfo^ info, 
    StreamingContext context
)
protected XmlException (
    SerializationInfo info, 
    StreamingContext context
)
protected function XmlException (
    info : SerializationInfo, 
    context : StreamingContext
)

パラメータ

info

XmlException のすべてのプロパティを格納している SerializationInfo オブジェクト。

context

コンテキスト情報を格納している StreamingContext オブジェクト。

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

XmlException コンストラクタ (String, Exception, Int32, Int32)

指定したメッセージ、内部例外、行番号、行の位置を使用して、XmlException クラスの新しいインスタンスを初期化します。

名前空間: System.Xml
アセンブリ: System.Xml (system.xml.dll 内)
構文構文

Public Sub New ( _
    message As String, _
    innerException As Exception, _
    lineNumber As Integer, _
    linePosition As Integer _
)
Dim message As String
Dim innerException As Exception
Dim lineNumber As Integer
Dim linePosition As Integer

Dim instance As New XmlException(message,
 innerException, lineNumber, linePosition)
public XmlException (
    string message,
    Exception innerException,
    int lineNumber,
    int linePosition
)
public:
XmlException (
    String^ message, 
    Exception^ innerException, 
    int lineNumber, 
    int linePosition
)
public XmlException (
    String message, 
    Exception innerException, 
    int lineNumber, 
    int linePosition
)
public function XmlException (
    message : String, 
    innerException : Exception, 
    lineNumber : int, 
    linePosition : int
)

パラメータ

message

エラーの説明。

innerException

現在の例外の原因である例外。この値は、null 参照 (Visual Basic では Nothing) の場合もあります。

lineNumber

エラーの発生場所を示す行番号。

linePosition

エラーの発生場所を示す行の位置。

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照

XmlException コンストラクタ


XmlException プロパティ


XmlException メソッド


パブリック メソッドパブリック メソッド

プロテクト メソッドプロテクト メソッド
参照参照

関連項目

XmlException クラス
System.Xml 名前空間

XmlException メンバ

最後の例外に関する詳細情報を返します。

XmlException データ型で公開されるメンバを以下の表に示します。


パブリック コンストラクタパブリック コンストラクタ
プロテクト コンストラクタプロテクト コンストラクタ
パブリック プロパティパブリック プロパティ
プロテクト プロパティプロテクト プロパティ
  名前 説明
プロテクト プロパティ HResult  特定の例外に割り当てられているコード化数値である HRESULT を取得または設定します。(Exception から継承されます。)
パブリック メソッドパブリック メソッド
プロテクト メソッドプロテクト メソッド
参照参照

関連項目

XmlException クラス
System.Xml 名前空間



英和和英テキスト翻訳

英語⇒日本語日本語⇒英語

辞書ショートカット

すべての辞書の索引

「XmlException」の関連用語

XmlExceptionのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



XmlExceptionのページの著作権

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2026 Microsoft.All rights reserved.

©2026 GRAS Group, Inc.RSS