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

OutputCacheSection.SendCacheControlHeader Property

Gets or sets a value indicating whether the cache-control:private header is sent by the output cache module by default.

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

<ConfigurationPropertyAttribute("sendCacheControlHeader", DefaultValue := True)> _
Public Property SendCacheControlHeader As Boolean

Property Value

Type: System.Boolean
true if the sending of cache-control:private header is enabled; otherwise, false. The default is true.

The SendCacheControlHeader applies to content with no output caching specified. When it is set to false, the cache-control:private header is not sent by default.


This setting enables the content to be cached on the client by default.

The following code example shows how to use the SendCacheControlHeader property.

' Get the current SendCacheControlHeader. 
  Dim sendCacheControlHeaderValue As [Boolean] = _

' Set the SendCacheControlHeader.
outputCacheSection.SendCacheControlHeader = False

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0
© 2015 Microsoft