Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <Window x:Class="Lab3.MainWindow"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- Title="MainWindow" Height="250" Width="525">
- <Grid Name="grid1">
- <Grid.RowDefinitions>
- <RowDefinition></RowDefinition>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition></ColumnDefinition>
- <ColumnDefinition></ColumnDefinition>
- </Grid.ColumnDefinitions>
- <ListBox Name="lstBox" Grid.Column="0" Grid.Row="0" DisplayMemberPath="ProductName">
- </ListBox>
- <StackPanel Name="spanel" Grid.Column="1" DataContext="{Binding ElementName=lstBox, Path=SelectedItem}">
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" >
- <Label>Quantity per user:</Label>
- <TextBox Width="150" Text="{Binding Path=QuantityPerUnit}"></TextBox>
- </StackPanel>
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" >
- <Label>Units in stock:</Label>
- <TextBox Width="150" Text="{Binding Path=UnitsInStock}"></TextBox>
- </StackPanel>
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" >
- <Label>Unit price:</Label>
- <TextBox Width="150" Text="{Binding Path=UnitPrice}"></TextBox>
- </StackPanel>
- <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Bottom" Height="200" >
- <Button Name="btn1" Width="250" Height="70" Click="btn1_Click" >Supplier Detail</Button>
- </StackPanel>
- </StackPanel>
- </Grid>
- </Window>
- <Window x:Class="Lab3.Details"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:local="clr-namespace:Lab3"
- Title="Details" Height="300" Width="300">
- <Grid>
- <Grid.RowDefinitions>
- <RowDefinition></RowDefinition>
- <RowDefinition></RowDefinition>
- <RowDefinition></RowDefinition>
- </Grid.RowDefinitions>
- <StackPanel Orientation="Horizontal" VerticalAlignment="Center">
- <Label>Company name:</Label>
- <TextBox Height="20" Text="{Binding CompanyName}"></TextBox>
- </StackPanel>
- <StackPanel Grid.Row="1" Orientation="Horizontal" VerticalAlignment="Center">
- <Label>Address:</Label>
- <TextBox Height="20" Text="{Binding Address}"></TextBox>
- </StackPanel>
- <StackPanel Grid.Row="2" Orientation="Horizontal" VerticalAlignment="Center">
- <Label>City:</Label>
- <TextBox Height="20" Text="{Binding City}"></TextBox>
- </StackPanel>
- </Grid>
- </Window>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement