123456789101112131415161718192021222324252627282930313233343536373839 |
- <Window x:Class="practice.Window1"
- 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:practice"
- mc:Ignorable="d"
- Title="Главная" Height="350" Width="625">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="2*"/>
- <ColumnDefinition Width="0.7*"/>
- <ColumnDefinition Width="1.3*"/>
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="0.5*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="*"/>
- </Grid.RowDefinitions>
- <DataGrid x:Name="inventoryGrid" Grid.Column="0" Grid.RowSpan="6" AutoGenerateColumns="False" IsReadOnly="True"
- SelectionChanged="inventoryGrid_SelectionChanged">
- <DataGrid.Columns>
- <DataGridTextColumn Header="Наименование" Binding="{Binding inventory_name}" Width="Auto"/>
- <DataGridTextColumn Header="Тип" Binding="{Binding inventory_type}" Width="Auto"/>
- </DataGrid.Columns>
- </DataGrid>
- <Label Content="Наименование" Grid.Column="1" Grid.Row="1" VerticalAlignment="Center" HorizontalAlignment="Right" FontSize="14"/>
- <TextBox x:Name="TbName" Grid.Column="2" Grid.Row="1" Height="30" Width="150"/>
- <Label Content="Тип" Grid.Column="1" Grid.Row="2" VerticalAlignment="Center" HorizontalAlignment="Right" FontSize="14"/>
- <TextBox x:Name="TbType" Grid.Column="2" Grid.Row="2" Height="30" Width="150"/>
- <Button Content="Добавить" Grid.Column="1" Grid.ColumnSpan="2" Grid.Row="3" Height="40" Width="150" Click="Insert_Click"/>
- <Button Content="Изменить" Grid.Column="1" Grid.ColumnSpan="2" Grid.Row="4" Height="40" Width="150" Click="Update_Click"/>
- <Button Content="Удалить" Grid.Column="1" Grid.ColumnSpan="2" Grid.Row="5" Height="40" Width="150" Click="Delete_Click"/>
- </Grid>
- </Window>
|