ValidationSummary.ErrorStyle Property

Silverlight

Gets or sets the style used for the error's item container.

Namespace:  System.Windows.Controls
Assembly:  System.Windows.Controls.Data.Input (in System.Windows.Controls.Data.Input.dll)

public Style ErrorStyle { get; set; }
<sdk:ValidationSummary>
  <sdk:ValidationSummary.ErrorStyle>
    inlineStyle
  </sdk:ValidationSummary.ErrorStyle>
</sdk:ValidationSummary>
<sdk:ValidationSummary ErrorStyle="styleReference"/>

XAML Values

inlineStyle

A single Style object element.

styleReference

A StaticResource reference to a Style.

Property Value

Type: System.Windows.Style
The style used for the error's item container.

Dependency property identifier field: ErrorStyleProperty

You can change the appearance of individual errors in the summary list by setting the ErrorStyle property to a custom Style.

Whether defined as an inline style or as a resource, the Style defines the appearance of items in the report, and should specify a TargetType of ListBoxItem (or derived type for a custom listbox). You typically specify setters for individual properties, and might also use a setter for the Template property if you wanted to change the composition of elements. For information that can help you decide whether to define styles inline or as resources, see Inline Styles and Templates.

Silverlight

Supported in: 5, 4, 3

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show: