Freigeben über


OutputCacheProfile.VaryByCustom Eigenschaft

Definition

Dient zum Abrufen oder Festlegen der VaryByCustom Eigenschaft.

public:
 property System::String ^ VaryByCustom { System::String ^ get(); void set(System::String ^ value); };
[System.Configuration.ConfigurationProperty("varyByCustom")]
public string VaryByCustom { get; set; }
[<System.Configuration.ConfigurationProperty("varyByCustom")>]
member this.VaryByCustom : string with get, set
Public Property VaryByCustom As String

Eigenschaftswert

Der VaryByCustom-Wert.

Attribute

Beispiele

Das folgende Codebeispiel zeigt, wie die VaryByCustom Eigenschaft verwendet wird.


// Get the current VaryByCustom.
String varyByCustomValue = 
    outputCacheProfile.VaryByCustom;

// Set the VaryByCustom.
outputCacheProfile.VaryByCustom = 
    string.Empty;
  ' Get the current VaryByCustom.
  Dim varyByCustomValue As String = _
  outputCacheProfile.VaryByCustom

  ' Set the VaryByCustom property.
  outputCacheProfile.VaryByCustom = _
  String.Empty

Hinweise

Dies VaryByCustom kann ein beliebiger Text sein, der benutzerdefinierte Anforderungen für die Ausgabezwischenspeicherung darstellt. Wenn eine benutzerdefinierte Zeichenfolge eingegeben wird, müssen Sie die Methode in der Datei "Global.asax" der GetVaryByCustomString Anwendung überschreiben.

Hinweis

Die VaryByCustom Einstellungen sind dieselben, die VaryByCustom vom Attribut der @ OutputCache Direktive verwendet werden.

Gilt für:

Weitere Informationen