WPF has turned on Validation in TextBox by default. How could I propagate a TextBox's Validation.Error up to its ItemsControl if its ItemTemplate is composed of the TextBox ? I want to bind a button's IsEnabled into the Validation.Error on an item in ItemsControl.
<ItemsControl ItemsSource="{Binding}"
x:Name="my_itemsControl">
<ItemsControl.ItemTemplate>
<DataTemplate>
<TextBox Text="{Binding FirstName}" />
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
<Button Content="Save">
<Button.IsEnabled >
<Binding ElementName="my_itemsControl"
Path="(Validation.HasError)" />
</Button.IsEnabled>
</Button>