Back to Devexpress

ValidationService.IsValidationContainer Attached Property

wpf-devexpress-dot-xpf-dot-editors-dot-validationservice-691f0cf1.md

latest1.8 KB
Original Source

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.v25.2.dll

NuGet Package : DevExpress.Wpf.Core

Declaration

See GetIsValidationContainer(DependencyObject) and SetIsValidationContainer(DependencyObject, Boolean).

Returns

TypeDescription
Boolean

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

|

Remarks

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

xaml
<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

ValidationService Class

ValidationService Members

DevExpress.Xpf.Editors Namespace