Click here to Skip to main content
11,709,033 members (62,776 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: WPF grid
-i used a GroupBox with a scrollviewer inside it ..and inside scrollviewer i put a grid and begin to put my controls (3 textblocks and 6 textboxes)
-after making my scrollviewer to scroll my content i faced a trouble of grid inside scrollviewer appear behind things like the next pic

http://www.4shared.com/photo/uAbOhsBX/q_online.html

and this is my XAML code ..i don't know if i miss something to do

<GroupBox BorderBrush="#FF0000DD" FontSize="13" FontWeight="Bold" Header="General Information" HorizontalAlignment="Stretch" Margin="363,20,38,368" Name="groupBox1" VerticalAlignment="Stretch" Panel.ZIndex="0">
                            <ScrollViewer Height="Auto" Name="scrollViewer1" Width="Auto" ScrollChanged="scrollViewer1_ScrollChanged" VerticalScrollBarVisibility="Auto" >
                                <Grid Name="grid1" Height="Auto">
                                    <Grid.RowDefinitions>
                                        <RowDefinition />
                                        <RowDefinition />
                                        <RowDefinition />
                                        <RowDefinition />
                                        <RowDefinition />
                                        <RowDefinition />
                                    </Grid.RowDefinitions>
                                    <Grid.ColumnDefinitions>
                                        <ColumnDefinition Width="2*" />
                                        <ColumnDefinition Width="*" />
                                    </Grid.ColumnDefinitions>
                                    <TextBlock Grid.Column="1" Grid.RowSpan="1" Height="Auto" HorizontalAlignment="Right" Margin="0" Name="textBlock1" Text="Generic ID" VerticalAlignment="Center" FontSize="14" Padding="0" />
                                    <TextBlock FontSize="14" Height="Auto" HorizontalAlignment="Right" Margin="0" Name="textBlock2" Text="Generic Name" VerticalAlignment="Center" Grid.Column="1" Grid.Row="1" Padding="0" />
                                    <TextBlock FontSize="14" Height="Auto" HorizontalAlignment="Right" Margin="0" Name="textBlock3" Text="Other Names" VerticalAlignment="Center" Grid.Column="1" Grid.Row="2" Padding="0" />
                                    <TextBox Height="23" HorizontalAlignment="Center" Margin="0" Name="textBox1" VerticalAlignment="Center" Width="197" Padding="0" />
                                    <TextBox Height="23" HorizontalAlignment="Center" Margin="0" Name="textBox2" VerticalAlignment="Center" Width="197" Grid.Row="1" Padding="0" />
                                    <TextBox Height="23" HorizontalAlignment="Center" Margin="0" Name="textBox3" VerticalAlignment="Center" Width="197" Grid.Row="2" Padding="0" />
                                    <TextBox Height="23" HorizontalAlignment="Center" Margin="0" Name="textBox4" VerticalAlignment="Center" Width="197" Grid.Row="3" Padding="0" />
                                    <TextBox Height="23" HorizontalAlignment="Center" Margin="0" Name="textBox5" VerticalAlignment="Center" Width="197" Grid.Row="4" Padding="0" />
                                    <TextBox Height="23" HorizontalAlignment="Center" Margin="0" Name="textBox6" VerticalAlignment="Center" Width="197" Grid.Row="5" Padding="0" />
                                </Grid>
                            </ScrollViewer>
                        </GroupBox>
Posted 12-Jan-13 2:10am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 580
1 Maciej Los 235
2 Peter Leow 219
3 OriginalGriff 214
4 Mika Wendelius 170
0 OriginalGriff 9,348
1 Sergey Alexandrovich Kryukov 8,727
2 CPallini 5,189
3 Maciej Los 4,991
4 Mika Wendelius 3,856


Advertise | Privacy | Mobile
Web03 | 2.8.150819.1 | Last Updated 12 Jan 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100