ugeb
asked on
What XAML would produce this?
I created a sample layout of my project, and I'm trying to use XAML (with C# in Visual Studio 2013) to implement it. My layout is somewhat wonkers (technical term). This is my desired layout:
And this is my xaml code:
What do I need to change to have buttons align and the text block stretch to the bottom of the window with a scroll bar?
Thanks!
And this is my xaml code:
<Window x:Class="SODA.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Height="420" Width="680">
<StackPanel Grid.RowSpan="7">
<DockPanel>
<Border BorderBrush="Blue" BorderThickness="0,10">
</Border>
<Menu DockPanel.Dock="Top" Height="30">
<MenuItem Header="_File">
</MenuItem>
<MenuItem Header="_Edit">
</MenuItem>
<MenuItem Header="Help">
</MenuItem>
</Menu>
</DockPanel>
<StackPanel Orientation="Horizontal">
<Label Content="Input File" FontWeight="Bold" FontSize="14"/>
<Button x:Name="cbInput" Content="cbInput" MinWidth="93" Margin="10,0,0,0"/>
<Button x:Name="cbEditInput" Click="btnBrowseWord_Click" MinWidth="93" Margin="10,0,0,0"
Content="Edit" ToolTip="Click to browse for Word Document Template"
Width="100" />
</StackPanel>
<ComboBox x:Name="cbxInput" Height="30" IsEditable="True"></ComboBox>
<StackPanel Orientation="Horizontal">
<Label Content="Reference File" FontWeight="Bold" FontSize="14"/>
<Button x:Name="cbReference" Content="cbInput" MinWidth="93" Margin="10,0,0,0"/>
<Button x:Name="cbEditRef" Click="btnBrowseWord_Click" MinWidth="93" Margin="10,0,0,0"
Content="Edit" ToolTip="Click to browse for Word Document Template"
Width="100" />
</StackPanel>
<ComboBox x:Name="cbxReference" Height="30" IsEditable="True"></ComboBox>
<StackPanel Orientation="Horizontal">
<Label Content="Output File" FontWeight="Bold" FontSize="14"/>
<Button x:Name="cbOutput" Content="cbOutput" MinWidth="93" Margin="10,0,0,0"/>
<Button x:Name="cbEditOut" Click="btnBrowseWord_Click" MinWidth="93" Margin="10,0,0,0"
Content="Edit" ToolTip="Click to browse for Word Document Template"
Width="100" />
</StackPanel>
<ComboBox x:Name="cbxOutput" Height="30" IsEditable="True"></ComboBox>
<Label Content="Messages" FontWeight="Bold" FontSize="14"/>
<TextBlock x:Name="txtBlkMessages" Height="Auto" Text="This section for messages." HorizontalAlignment="Left"/>
</StackPanel>
</Window>
What do I need to change to have buttons align and the text block stretch to the bottom of the window with a scroll bar?
Thanks!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you for the help. I found out that the margins control that spacing.
ASKER