共用方式為


MalformedLineException 建構函式

定義

初始化 MalformedLineException 類別的新執行個體。

多載

名稱 Description
MalformedLineException()

初始化 MalformedLineException 類別的新執行個體。

MalformedLineException(String)

初始化類別的新實例 MalformedLineException 並指定錯誤訊息。

MalformedLineException(SerializationInfo, StreamingContext)
已淘汰.

初始化一個新的類別實例 MalformedLineException ,並使用序列化資料。

MalformedLineException(String, Exception)

初始化類別的新實例 MalformedLineException ,並附上指定的錯誤訊息及導致該異常的內部例外的參考。

MalformedLineException(String, Int64)

初始化一個新的類別實例 MalformedLineException ,並附上指定的錯誤訊息和行號。

MalformedLineException(String, Int64, Exception)

初始化一個新的類別實例 MalformedLineException ,包含指定的錯誤訊息、行號,以及導致該例外的內部例外的參考。

MalformedLineException()

來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb

初始化 MalformedLineException 類別的新執行個體。

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

備註

例外表示 ReadFields 該方法無法使用指定格式解析資料列。

下表顯示了 的 MalformedLineException初始屬性值。

房產 價值
InnerException 一個空參考(Nothing Visual Basic 中的 Reference)。
Message 區域化錯誤訊息字串。

另請參閱

適用於

MalformedLineException(String)

來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb

初始化類別的新實例 MalformedLineException 並指定錯誤訊息。

public:
 MalformedLineException(System::String ^ message);
public MalformedLineException(string? message);
public MalformedLineException(string message);
new Microsoft.VisualBasic.FileIO.MalformedLineException : string -> Microsoft.VisualBasic.FileIO.MalformedLineException
Public Sub New (message As String)

參數

message
String

一則描述錯誤的訊息。

備註

參數的內容 message 是為了讓人類理解而設計的。 此建構器的呼叫者必須確保此字串已在目前系統文化中本地化。

MalformedLineException 繼承自該 Exception 類別。 此建構器設定物件的 Exception 屬性如下表所示。

房產 價值
InnerException 一個空參考(Nothing Visual Basic 中的)
Message 那條 message 線。

適用於

MalformedLineException(SerializationInfo, StreamingContext)

來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb

警告

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

初始化一個新的類別實例 MalformedLineException ,並使用序列化資料。

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

參數

info
SerializationInfo

存放 SerializationInfo 關於被拋出例外的序列化物件資料的物件。

context
StreamingContext

StreamingContext包含關於來源或目的地的上下文資訊的結構。

屬性

備註

此建構子在反序列化過程中被呼叫,以重建透過串流傳輸的例外物件。

適用於

MalformedLineException(String, Exception)

來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb

初始化類別的新實例 MalformedLineException ,並附上指定的錯誤訊息及導致該異常的內部例外的參考。

public:
 MalformedLineException(System::String ^ message, Exception ^ innerException);
public MalformedLineException(string? message, Exception? innerException);
public MalformedLineException(string message, Exception innerException);
new Microsoft.VisualBasic.FileIO.MalformedLineException : string * Exception -> Microsoft.VisualBasic.FileIO.MalformedLineException
Public Sub New (message As String, innerException As Exception)

參數

message
String

String描述錯誤。

innerException
Exception

造成 Exception 當前例外的物件。 如果參數 InnerException 不是 null 參考(Nothing 在 Visual Basic 中),目前的例外會在處理內部異常的 catch 區塊中提出。

備註

參數的內容 message 是為了讓人類理解而設計的。 此建構器的呼叫者必須確保此字串已在目前系統文化中本地化。

因先前例外直接拋出的例外,應包含對該屬性中 InnerException 先前例外的參考。 該 InnerException 屬性回傳與傳入建構子相同的值;若該 InnerException 屬性未提供內部例外值,則回傳為空參考。

下表顯示了 的 ApplicationException初始屬性值。

房產 價值
InnerException 那個 innerException 參考。
Message 那條 message 線。

適用於

MalformedLineException(String, Int64)

來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb

初始化一個新的類別實例 MalformedLineException ,並附上指定的錯誤訊息和行號。

public:
 MalformedLineException(System::String ^ message, long lineNumber);
public MalformedLineException(string? message, long lineNumber);
public MalformedLineException(string message, long lineNumber);
new Microsoft.VisualBasic.FileIO.MalformedLineException : string * int64 -> Microsoft.VisualBasic.FileIO.MalformedLineException
Public Sub New (message As String, lineNumber As Long)

參數

message
String

例外的訊息。

lineNumber
Int64

那條錯誤的線路號碼。

備註

參數的內容 message 是為了讓人類理解而設計的。 此建構器的呼叫者必須確保此字串已在目前系統文化中本地化。 參數 lineNumber 初始化了該 LineNumber 性質。

MalformedLineException 繼承自 Exception。 此建構器設定物件的 Exception 屬性如下表所示。

房產 價值
InnerException 一個空參考(Nothing Visual Basic 中的)
Message 那條 message 線。

適用於

MalformedLineException(String, Int64, Exception)

來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb
來源:
MalformedLineException.vb

初始化一個新的類別實例 MalformedLineException ,包含指定的錯誤訊息、行號,以及導致該例外的內部例外的參考。

public:
 MalformedLineException(System::String ^ message, long lineNumber, Exception ^ innerException);
public MalformedLineException(string? message, long lineNumber, Exception? innerException);
public MalformedLineException(string message, long lineNumber, Exception innerException);
new Microsoft.VisualBasic.FileIO.MalformedLineException : string * int64 * Exception -> Microsoft.VisualBasic.FileIO.MalformedLineException
Public Sub New (message As String, lineNumber As Long, innerException As Exception)

參數

message
String

例外的訊息。

lineNumber
Int64

那條錯誤的線路號碼。

innerException
Exception

這就是 Exception 目前例外的原因。 如果參數 InnerException 不是 null 參考(Nothing 在 Visual Basic 中),目前的例外會在處理內部異常的 catch 區塊中提出。

備註

參數的內容 message 是為了讓人類理解而設計的。 此建構器的呼叫者必須確保此字串已在目前系統文化中本地化。 參數 lineNumber 初始化了該 LineNumber 性質。

因先前例外直接拋出的例外,應包含對該屬性中 InnerException 先前例外的參考。 該 InnerException 屬性回傳與傳入建構子相同的值;若該 InnerException 屬性未提供內部例外值,則回傳為空參考。

下表顯示了 的 ApplicationException初始屬性值。

房產 價值
InnerException 那個 innerException 參考。
Message 那條 message 線。

適用於