Compartir por


OutputCacheSection.EnableFragmentCache Propiedad

Definición

Obtiene o establece un valor que indica si la caché de fragmentos está habilitada.

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

Valor de propiedad

true si la caché de fragmentos está habilitada; de lo contrario, false. El valor predeterminado es true.

Atributos

Ejemplos

En el ejemplo de código siguiente se muestra cómo usar la EnableFragmentCache propiedad .


// Get the current EnabledFragmentCache.
Boolean enabledFragmentCache =
    outputCacheSection.EnableFragmentCache;

// Set the EnabledFragmentCache.
outputCacheSection.EnableFragmentCache = false;
' Get the current EnabledFragmentCache.
  Dim enabledFragmentCache As [Boolean] = _
  outputCacheSection.EnableFragmentCache

' Set the EnabledFragmentCache.
outputCacheSection.EnableFragmentCache = False

Comentarios

Si la EnableFragmentCache propiedad se establece falseen , no se almacena en caché ninguna salida de control de usuario, independientemente de la directiva @ OutputCache o del perfil de almacenamiento en caché usado. Para obtener más información, vea OutputCacheSettingsSection y OutputCacheProfile.

Se aplica a

Consulte también