<Window x:Class="ExceptionValidationRule_Sample.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
        xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
        xmlns:local="clr-namespace:ExceptionValidationRule_Sample"
        mc:Ignorable="d"
        Title="ExceptionValidationRule_Sample" Height="150" Width="400" FontSize="16">
    <Window.Background>
        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
            <GradientStop Color="Black" Offset="0"/>
            <GradientStop Color="White" Offset="1"/>
        </LinearGradientBrush>
    </Window.Background>

    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="Auto"/>
            <ColumnDefinition/>
        </Grid.ColumnDefinitions>
        <Label Foreground="White">Aktuelle Objektdaten:</Label>
        <Label Foreground="White" Grid.Column="1">Objektdaten ändern:</Label>
        <Label Foreground="White" Grid.Row="1" Content="{Binding Age}"></Label>
        <TextBox Grid.Column="1" Grid.Row="1" Margin="8" Text="{Binding Age, UpdateSourceTrigger=PropertyChanged, ValidatesOnExceptions=True}" />
    </Grid>
</Window>

