Skip to main content
Tab

ASPxGridBehaviorSettings.EncodeErrorHtml Property

SECURITY NOTE

Disabling this property may introduce security-related issues. Review the following help topic and learn how to protect websites from cross-site scripting (XSS) attacks: HTML Encoding.

Gets or sets whether to encode error row content.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v24.1.dll

NuGet Package: DevExpress.Web

Declaration

[DefaultValue(true)]
public bool EncodeErrorHtml { get; set; }

Property Value

Type Default Description
Boolean true

true to encode error row content and display it as text, false to not encode error row content and render it as HTML markup.

Remarks

Find control-specific information (for ASPxGridView, ASPxCardView or ASPxVerticalGrid) in the sections below.

ASPxGridView

If the EncodeErrorHtml property is set to true, the error row content that contains HTML code is parsed so that any angle bracket (the characters < and >) of HTML tags is converted to specific symbols (&lt; and &gt;) when the grid renders its row errors. This allows the HTML code to be represented on the page as text:

EncodeErrorHtml_True

If this property is set to false, the row errors that contain HTML tags are not specifically parsed and are rendered as pure HTML markup. This allows the result of the HTML code to be displayed in the grid:

EncodeErrorHtml_False

Grid View - Get Started

ASPxCardView

If the EncodeErrorHtml property is set to true, a card error text that contain HTML code is parsed so that any angle bracket (the characters < and >) is converted to specific symbols (&lt; and &gt;) when the grid renders its card errors. This allows the HTML code to be represented on the page as text.

If this property is set to false, the card errors that contain HTML tags are not specifically parsed and are rendered as pure HTML markup. This allows the result of the HTML code to be displayed in the grid.

Card View - Get Started

ASPxVerticalGrid

If the EncodeErrorHtml property is set to true, a record error text that contain HTML code is parsed so that any angle bracket (the characters < and >) is converted to specific symbols (&lt; and &gt;) when the grid renders its record errors. This allows the HTML code to be represented on the page as text.

If this property is set to false, the record errors that contain HTML tags are not specifically parsed and are rendered as pure HTML markup. This allows the result of the HTML code to be displayed in the grid.

Vertical Grid - Get Started

Note

The EncodeErrorHtml property has effect only for GridErrorTextKind.RowValidate errors.

See Also