XamlParseException 建構函式
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
初始化 XamlParseException 類別的新執行個體。
多載
| 名稱 | Description |
|---|---|
| XamlParseException() |
初始化該類別的新實例 XamlParseException ,並以系統提供的訊息描述錯誤。 |
| XamlParseException(String) |
初始化類別的新實例 XamlParseException ,並以指定訊息描述錯誤。 |
| XamlParseException(SerializationInfo, StreamingContext) |
使用串行化數據,初始化 XamlParseException 類別的新實例。 |
| XamlParseException(String, Exception) |
初始化類別的新實例 XamlParseException ,並附上指定的錯誤訊息及導致該異常的內部例外的參考。 |
XamlParseException()
初始化該類別的新實例 XamlParseException ,並以系統提供的訊息描述錯誤。
public:
XamlParseException();
public XamlParseException();
Public Sub New ()
適用於
XamlParseException(String)
初始化類別的新實例 XamlParseException ,並以指定訊息描述錯誤。
public:
XamlParseException(System::String ^ message);
public XamlParseException(string message);
new System.Xaml.XamlParseException : string -> System.Xaml.XamlParseException
Public Sub New (message As String)
參數
- message
- String
描述例外的訊息。 此建構器的呼叫者必須確保此字串已在目前系統文化中本地化。
適用於
XamlParseException(SerializationInfo, StreamingContext)
使用串行化數據,初始化 XamlParseException 類別的新實例。
protected:
XamlParseException(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected XamlParseException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
new System.Xaml.XamlParseException : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Xaml.XamlParseException
Protected Sub New (info As SerializationInfo, context As StreamingContext)
參數
- info
- SerializationInfo
存放序列化物件資料的物件。
- context
- StreamingContext
關於來源或目的地的上下文資訊。
適用於
XamlParseException(String, Exception)
初始化類別的新實例 XamlParseException ,並附上指定的錯誤訊息及導致該異常的內部例外的參考。
public:
XamlParseException(System::String ^ message, Exception ^ innerException);
public XamlParseException(string message, Exception innerException);
new System.Xaml.XamlParseException : string * Exception -> System.Xaml.XamlParseException
Public Sub New (message As String, innerException As Exception)
參數
- message
- String
描述例外的訊息。 此建構器的呼叫者必須確保此字串已在目前系統文化中本地化。
- innerException
- Exception
該例外即為當前例外的原因。 若 innerException 參數不 null為 ,則在處理內部異常的區塊中提出 catch 當前例外。
備註
因先前例外直接拋出的例外,應包含對該屬性中 InnerException 先前例外的參考。 該 InnerException 屬性回傳與傳入建構子相同的值,或 null 若該 InnerException 性質未提供內部例外值給建構子。