<Window x:Class="Sample1.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:Sample1"
        mc:Ignorable="d"
     Title="Sample1" Height="200" Width="300">
    <Window.CommandBindings>
        <CommandBinding Command="ApplicationCommands.Print"
                        CanExecute="Print_CanExecute"
                        Executed="Print_Executed" />
    </Window.CommandBindings>
    <DockPanel>
        <Menu DockPanel.Dock="Top">
            <MenuItem Header="Datei">
                <MenuItem Command="ApplicationCommands.Print" />
            </MenuItem>
        </Menu>
        <ToolBarTray DockPanel.Dock="Top">
            <ToolBar>
                <Button Command="ApplicationCommands.Print">
                    <Image Source="Print_11009.png" />
                </Button>
            </ToolBar>
        </ToolBarTray>
        <TextBox Name="txtContent" Margin="5" Background="AliceBlue"/>
    </DockPanel>
</Window>

