Context.Response Object

Description

Context.Response object properties and methods.

Properties

CacheSystem::Web::HttpCachePolicy

Context.Response.Cache is used to control the cache HTTP headers. See the Microsoft documentation for HttpCachePolicy for more details. Read Only.

ContentEncodingSystem::Text::Encoding

Context.Response.ContentEncoding is used to get or set the content encoding of the response. Read Write.

ContentTypeCharacter

Context.Response.ContentType is used to get or set the MIME type of the response content. It defaults to "text/html". Read Write.

CookiesSystem::Web::HttpCookieCollection

Context.Response.Cookies is the collection of the current response's cookies. Read Only.

HeadersSystem::Collections::Specialized::NameValueCollection

Context.Response.Headers is the collection of the current response's HTTP headers. Read Only.

OutputStreamSystem::IO::Stream

Context.Response.OutputStream is the raw contents of the HTTP response content. Read Only.

RedirectLocationCharacter

Context.Response.RedirectLocation is used to get or set the absolute URI that will be sent in the Location header of the response. Read Write.

StatusCodeNumeric

Context.Response.StatusCode is used to get or set HTTP status code of the response. Read Write.

StatusDescriptionCharacter

Context.Response.StatusDescription is used to get or set the description for the StatusCode of the response. Read Write.

Methods

AppendCookie Method

Adds a cookie to the response's cookie collection.

AppendHeader Method

Adds an HTTP header to the current response.

BinaryWrite Method

Write bytes to the response's output stream.

Clear Method

Removes all content from the OutputStream.

ClearContent Method

Alias for Clear.

ClearHeaders Method

Removes all HTTP headers

End Method

Completes response with no further processing

GetCookie Method

Returns a cookie if the cookie exists.

HasCookie Method

Tests if a cookie exists.

NoCache Method

Configures the response so browser will not cache it.

Redirect Method

Redirect the client and optionally terminate processing the current page

RedirectPermanent Method

Redirect the client and optionally terminate processing the current page

SendFile Method

Write the content of a file to output stream

SetHeader Method

Sets an HTTP header to the current response.

Write Method

Write a character, binary, number or logical to output stream