I an using a Scrollviewer with an ItemsControl in it. the VerticalScrollBarVisibility of the Scrollviewer is set to "Auto". the problem is that when the scrollbar appears it shifts the contents of the ItemsControl horizontally.
Is there a way that the scroll bar will just be "over" the contents with out moving them?
the code looks something like this
<ScrollViewer VerticalScrollBarVisibility="Auto" CanContentScroll="True" SnapsToDevicePixels="True">
<ItemsControl ItemsSource="{Binding Summaries}" >
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<StackPanel Orientation="Vertical" IsItemsHost="True" CanVerticallyScroll="True" />
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
<ItemsControl.ItemTemplate>
<DataTemplate>
<Grid Margin="15,5,10,5" HorizontalAlignment="Stretch">
<Grid.ColumnDefinitions>
<ColumnDefinition Width=".166*"></ColumnDefinition>
<ColumnDefinition Width=".166*"></ColumnDefinition>
<ColumnDefinition Width=".166*"></ColumnDefinition>
<ColumnDefinition Width=".166*"></ColumnDefinition>
<ColumnDefinition Width=".166*"></ColumnDefinition>
<ColumnDefinition Width=".166*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="{Binding Name}" VerticalAlignment="Center" HorizontalAlignment="Left"/>
<Label Grid.Column="1" Content="{Binding A}" HorizontalContentAlignment="Center"/>
<Label Grid.Column="2" Content="{Binding B}" HorizontalAlignment="Center" HorizontalContentAlignment="Stretch"/>
<Label Grid.Column="3" Content="{Binding C}" HorizontalAlignment="Center" HorizontalContentAlignment="Stretch"/>
<Label Grid.Column="4" Content="{Binding D}" HorizontalAlignment="Center" HorizontalContentAlignment="Stretch"/>
<Label Grid.Column="5" Content="{Binding E}" HorizontalAlignment="Center" HorizontalContentAlignment="Stretch"/>
</Grid>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl></ScrollViewer>
Thanks