System.Web.Configuration.CacheSection.DisableExpiration Property

Gets or sets a value indicating whether the cache expiration is disabled.

Syntax

[System.Configuration.ConfigurationProperty("disableExpiration", DefaultValue="False")]
public bool DisableExpiration { set; get; }

Value

Documentation for this section has not yet been entered.

Remarks

If the CacheSection.DisableExpiration property is set to true, the cached items never expire. This setting is intended to help debug cache behavior in application code. Use caution when disabling cache expiration, as this might result in items being cached longer than they are valid.

Note:

To add a page to the output cache, you must establish an expiration policy for that page. You can do this declaratively with the @ OutputCache directive or programmatically using the System.Web.HttpCachePolicy.SetExpires(DateTime) method. For more information, see How to: Set Expirations for Page Caching.

Requirements

Namespace: System.Web.Configuration
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0