ContentResult Class

Definition

Represents a user-defined content type that is the result of an action method.

public class ContentResult : System.Web.Mvc.ActionResult
type ContentResult = class
    inherit ActionResult
Public Class ContentResult
Inherits ActionResult
Inheritance
ContentResult

Constructors

Name Description
ContentResult()

Initializes a new instance of the ContentResult class.

Properties

Name Description
Content

Gets or sets the content.

ContentEncoding

Gets or sets the content encoding.

ContentType

Gets or sets the type of the content.

Methods

Name Description
ExecuteResult(ControllerContext)

Enables processing of the result of an action method by a custom type that inherits from the ActionResult class.

Applies to