HttpCompileException 建構函式

定義

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

多載

名稱 Description
HttpCompileException()

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

HttpCompileException(String)

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

HttpCompileException(CompilerResults, String)

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

HttpCompileException(String, Exception)

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

HttpCompileException()

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

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

適用於

HttpCompileException(String)

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

public:
 HttpCompileException(System::String ^ message);
public HttpCompileException(string message);
new System.Web.HttpCompileException : string -> System.Web.HttpCompileException
Public Sub New (message As String)

參數

message
String

例外訊息用來指定錯誤發生時。

適用於

HttpCompileException(CompilerResults, String)

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

public:
 HttpCompileException(System::CodeDom::Compiler::CompilerResults ^ results, System::String ^ sourceCode);
public HttpCompileException(System.CodeDom.Compiler.CompilerResults results, string sourceCode);
new System.Web.HttpCompileException : System.CodeDom.Compiler.CompilerResults * string -> System.Web.HttpCompileException
Public Sub New (results As CompilerResults, sourceCode As String)

參數

results
CompilerResults

CompilerResults一個包含編譯器輸出與錯誤資訊的編譯器。

sourceCode
String

錯誤發生時,包含原始碼的檔案路徑。

備註

對於 sourceCode 參數,你可以傳遞任何描述錯誤條件的字串資訊;檔案或路徑不需檢查。 該 SourceCode 屬性會回傳作為參數值的字串。 若使用不需參數的 sourceCode 建構子,性質 SourceCodenull

適用於

HttpCompileException(String, Exception)

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

public:
 HttpCompileException(System::String ^ message, Exception ^ innerException);
public HttpCompileException(string message, Exception innerException);
new System.Web.HttpCompileException : string * Exception -> System.Web.HttpCompileException
Public Sub New (message As String, innerException As Exception)

參數

message
String

說明例外狀況原因的錯誤訊息。

innerException
Exception

該例外即為當前例外的原因。 如果 innerException 不是 null,則會在處理內部例外狀況的 catch 區塊中引發目前的例外狀況。

適用於