Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
EnableKernelOutputCache Property

HttpRuntimeSection.EnableKernelOutputCache Property

Gets or sets a value that indicates whether output caching is enabled.

Namespace: System.Web.Configuration
Assembly: System.Web (in system.web.dll)

public:
property bool EnableKernelOutputCache {
	bool get ();
	void set (bool value);
}
/** @property */
public boolean get_EnableKernelOutputCache ()

/** @property */
public void set_EnableKernelOutputCache (boolean value)

public function get EnableKernelOutputCache () : boolean

public function set EnableKernelOutputCache (value : boolean)

Not applicable.

Property Value

true if output caching is enabled; otherwise, false. The default value is true.

In order to cache a response, the following criteria need to be met:

  • Caching must be explicitly enabled by a page directive or by the caching API.

  • Caching must have an expiration policy so that the kernel knows when to discard it.

  • Caching cannot have any variable headers or parameters.

  • The request must not require any authentication.

NoteNote:

This property is relevant only when Internet Information Services (IIS) version 6.0 or later is installed.

The following example shows how to use the EnableKernelOutputCache property.

No code example is currently available or this language may not be supported.

Windows 98, Windows Server 2000 SP4, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0

Community Additions

ADD
Show:
© 2015 Microsoft