PartialCachingAttribute.VaryByControls Özellik
Tanım
Önemli
Bazı bilgiler ürünün ön sürümüyle ilgilidir ve sürüm öncesinde önemli değişiklikler yapılmış olabilir. Burada verilen bilgilerle ilgili olarak Microsoft açık veya zımni hiçbir garanti vermez.
Çıkış önbelleğinin kullanıcı denetimini değiştirmek için kullandığı kullanıcı denetimi özelliklerinin listesini alır.
public:
property System::String ^ VaryByControls { System::String ^ get(); };
public:
property System::String ^ VaryByControls { System::String ^ get(); void set(System::String ^ value); };
public string VaryByControls { get; }
public string VaryByControls { get; set; }
member this.VaryByControls : string
member this.VaryByControls : string with get, set
Public ReadOnly Property VaryByControls As String
Public Property VaryByControls As String
Özellik Değeri
Kullanıcı denetimi özelliklerinin listesi.
Örnekler
Aşağıdaki kod örneği, oluşturucunun PartialCachingAttribute(Int32, String, String, String) bir kullanıcı denetimine nasıl uygulanabileceğini gösterir. Örnekte oluşturucu, kullanıcı denetiminin önbelleğe alınabileceğini belirtmek, önbelleğe alma süresini 20 saniye olarak belirtmek ve kullanıcı denetimi çıkışının değişeceği adlı state
bir denetim belirtmek için kullanılır.
// Set the PartialCachingAttribute.Duration property to
// 20 seconds and the PartialCachingAttribute.VaryByControls
// property to the ID of the server control to vary the output by.
// In this case, it is state, the ID assigned to a DropDownList
// server control.
[PartialCaching(20, null, "state", null)]
' Set the PartialCachingAttribute.Duration property to
' 20 seconds and the PartialCachingAttribute.VaryByControls
' property to the ID of the server control to vary the output by.
' In this case, it is state, the ID assigned to a DropDownList
' server control.
<PartialCaching(20, Nothing, "state", Nothing)> _
Public Class ctlSelect
Inherits UserControl
Şunlara uygulanır
Geri Bildirim
https://aka.ms/ContentUserFeedback.
Çok yakında: 2024 boyunca, içerik için geri bildirim mekanizması olarak GitHub Sorunları’nı kullanımdan kaldıracak ve yeni bir geri bildirim sistemiyle değiştireceğiz. Daha fazla bilgi için bkz.Gönderin ve geri bildirimi görüntüleyin