HttpCompileException 建構函式

定義

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

多載

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 ,則 SourceCode 屬性為 null

適用於

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 區塊中引發。

適用於