This is a migrated thread and some comments may be shown as answers.

Scrollviewer - Rad Grid View Vertical scroll bar not visible

2 Answers 752 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Shipra
Top achievements
Rank 1
Shipra asked on 19 Sep 2010, 12:54 PM
Hi!
When I enclose the Rad Grid View in the scroll viewer, if you shrink the brower window, the vertical scroll bar gets invisible and have to use horizontal scroll bar to see it. Please see attached jpeg and code example -

 

 

 

 

<ScrollViewer HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto">
    <Grid x:Name="LayoutRoot" DataContext="{StaticResource MyViewModel}">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*"/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="200" MinHeight="40"/>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>
        <Grid Grid.Row="0">
            <Grid.RowDefinitions>
                <RowDefinition Height="*"/>
                <RowDefinition Height="Auto"/>
            </Grid.RowDefinitions>
            <telerikGridViewControls:RadGridView Grid.Row="0" 
                         ItemsSource="{Binding Players}"
                         AutoGenerateColumns="False" ShowGroupPanel="False" 
                         >
                <telerikGridViewControls:RadGridView.Columns>
                    <telerikGridViewControls:GridViewDataColumn DataMemberBinding="{Binding Name}"/>
                    <telerikGridViewControls:GridViewDataColumn DataMemberBinding="{Binding Number}"/>
                    <telerikGridViewControls:GridViewDataColumn DataMemberBinding="{Binding Country}"/>
                </telerikGridViewControls:RadGridView.Columns>
            </telerikGridViewControls:RadGridView>
            <TextBox Grid.Row="1" Text="Action View" Visibility="Collapsed"/>
        </Grid>
        <controls:GridSplitter x:Name="HorizontalGrdSplitter" Grid.Row="1" Height="5" HorizontalAlignment="Stretch"
                               VerticalAlignment="Top" Background ="DarkGray"/>
        <Grid Grid.Row="2">
            <Grid.RowDefinitions>
                <RowDefinition Height="200"/>
                <RowDefinition Height="200"/>
            </Grid.RowDefinitions>
            <TextBox Grid.Row="0" Text="hello 1"/>
            <TextBox Grid.Row="1" Text="hello 2"/>
        </Grid>
    </Grid>
</ScrollViewer>         

2 Answers, 1 is accepted

Sort by
0
Milan
Telerik team
answered on 20 Sep 2010, 11:50 AM
Hi Shipra,

This is the natural behavior of the ScrollViewer control - if there is not enough space to show the contents, in this case RadGridView, a horizontal scrollbar appears. 


Regards,
Milan
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Shipra
Top achievements
Rank 1
answered on 20 Sep 2010, 07:13 PM
Yes, of course the horizontal scroll bar appears, but we want vertical scroll bar on the grid to be always visible, when the browser window is shrunk. Currently you have to use the horizontal scroll bar on the grid, to scroll to the right to see vertical scroll bar on the grid. I hope it makes sense. Alternatively, can the vertical scroll bar on the grid be moved to left, so it is always visible. Please reply soon.

Thanks
Shipra
Tags
GridView
Asked by
Shipra
Top achievements
Rank 1
Answers by
Milan
Telerik team
Shipra
Top achievements
Rank 1
Share this question
or