Skip to main content
A newer version of this page is available. .
All docs
V21.2

ValidationService.IsValidationContainer Attached Property

Allows you to to catch validation errors within a visual container. This is an attached property.

Namespace: DevExpress.Xpf.Editors

Assembly: DevExpress.Xpf.Core.v21.2.dll

NuGet Package: DevExpress.Wpf.Core

Declaration

Returns

Type Description
Boolean

true, to catch validation errors within a visual container; otherwise, false.

Remarks

To use the ValidationService with a GridControl, set the IsValidationContainer property to true for the GridControl.

The code snippet below illustrates how to catch validation errors for the child elements of a LayoutControl.

<UserControl ... >
    ...
    <dxlc:LayoutControl ... x:Name="container"
                  dxe:ValidationService.IsValidationContainer="True">
        ...
        <dxe:TextEdit ... />  
        <Button Visibility="{Binding ElementName=w1, Path=(dxe:ValidationService.HasValidationError), Converter={dx:BooleanToVisibilityConverter Invert=True}}" ... />  
    </dxlc:LayoutControl>
</UserControl>
See Also