OutputCacheProfile.VaryByControl 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
取得或設定該 VaryByControl 屬性。
public:
property System::String ^ VaryByControl { System::String ^ get(); void set(System::String ^ value); };
[System.Configuration.ConfigurationProperty("varyByControl")]
public string VaryByControl { get; set; }
[<System.Configuration.ConfigurationProperty("varyByControl")>]
member this.VaryByControl : string with get, set
Public Property VaryByControl As String
屬性值
- 屬性
範例
以下程式碼範例說明如何使用該 VaryByControl 屬性。
// Get the current VaryByControl.
String varyByControlValue =
outputCacheProfile.VaryByControl;
// Set the VaryByControl.
outputCacheProfile.VaryByControl =
string.Empty;
' Get the current VaryByControl.
Dim varyByControlValue As String = _
outputCacheProfile.VaryByControl
' Set the VaryByControl.
outputCacheProfile.VaryByControl = _
String.Empty
備註
這是 VaryByControl 一組以分號分隔的控制項 ID,需快取。
欲了解更多資訊,請參閱「 快取多版本使用者控制輸出」。
Note
設定VaryByControl與指令屬性所使用的VaryByControl@ OutputCache相同。