View Code
<Trigger Property="Validation.HasError" Value="True"> <Setter TargetName="Bd" Property="BorderBrush" Value="Red"/> </Trigger>
View Code
<Setter Property="Validation.ErrorTemplate"> <Setter.Value> <ControlTemplate> <!--<AdornedElementPlaceholder> <Border BorderBrush="Red" BorderThickness="1" CornerRadius="5" SnapsToDevicePixels="True" /> </AdornedElementPlaceholder>--> </ControlTemplate> </Setter.Value> </Setter>
View Code
<Setter Property="Validation.ErrorTemplate" Value="{DynamicResource InputErrorTemplate}" /> <Style.Triggers> <Trigger Property="Validation.HasError" Value="True"> <Setter Property="ToolTip"> <Setter.Value> <Binding Path="(Validation.Errors).CurrentItem.ErrorContent" RelativeSource="{x:Static RelativeSource.Self}" /> </Setter.Value> </Setter> </Trigger> </Style.Triggers>