Bagikan melalui


OutputCacheProfile.VaryByControl Properti

Definisi

Mendapatkan atau mengatur VaryByControl properti.

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

Nilai Properti

Nilai VaryByControl.

Atribut

Contoh

Contoh kode berikut menunjukkan cara menggunakan VaryByControl properti .


// 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

Keterangan

VaryByControl adalah set kontrol yang dibatasi titik koma yang akan di-cache.

Untuk informasi selengkapnya, lihat Penembolokan Beberapa Versi Output Kontrol Pengguna.

Nota

Pengaturan VaryByControl adalah pengaturan yang sama yang digunakan oleh VaryByControl atribut @ OutputCache direktif.

Berlaku untuk

Lihat juga