ServiceHostingEnvironmentSection.AspNetCompatibilityEnabled 屬性

定義

取得或設定布林值 (Boolean),這個值會指定是否已為目前的應用程式啟用 ASP.NET 相容性模式。

public:
 property bool AspNetCompatibilityEnabled { bool get(); void set(bool value); };
[System.Configuration.ConfigurationProperty("aspNetCompatibilityEnabled", DefaultValue=false)]
public bool AspNetCompatibilityEnabled { get; set; }
[<System.Configuration.ConfigurationProperty("aspNetCompatibilityEnabled", DefaultValue=false)>]
member this.AspNetCompatibilityEnabled : bool with get, set
Public Property AspNetCompatibilityEnabled As Boolean

屬性值

如果已為目前的應用程式啟用 ASP.NET 相容性模式,則為 true,否則為 false。 預設為 false

屬性

備註

當此屬性設定為 true 時,禁止對 Windows Communication Foundation (WCF) 服務的要求流經 ASP.NET HTTP 管線,並禁止透過非 HTTP 通訊協定進行通訊。

適用於