scrollviewer

Vertical scroll bar does not appear when the gridview items exceeded the display height

I place the following statements in the second row of my grid in the xaml: <ScrollViewer VerticalScrollBarVisibility="Auto" Grid.Row="1"> <ListView Name="listView" Margin="5" Grid.Row="1"> <ListView.View> <GridView AllowsColumnReorder="True"> <GridViewColumn DisplayMember...

Silverlight Scrollviewer With Only Buttons

I am using a ScrollViewer as part of my Silverlight application. It has a horizontal orientation, and I would like it to appear such that only the scroll buttons appear, but not the scroll bar itself. Something like this crude ASCII rendering: ------------------------------------------------------ | | ...

How to place a ScrollViewer on top of the content it should scroll

I would like to put my ScrollViewer in such a way that it overlaps/sits on top of the content it scrolls. I would set the Opacity of the ScrollViewer so that the content is visible underneath. As far as I understand the default ScrollViewer, this doesn't seem to be possible out of the box since the content is nested inside the ScrollVie...

WPF - Animate ListBox.ScrollViewer.HorizontalOffset?

I have a collection of Visuals in a ListBox. I need to find the XPosition of an element inside it and then animate the HorizontalOffset of the ListBox's ScrollViewer. Essentially I want to created an animated ScrollIntoView method. This gives me a couple of problems. Firstly, how can I get a reference to the ListBoxs scrollviewer? Se...

How do I add an extended class ScrollViewer to the XAML file?

I was looking for a way to animate the scrolling of a ScrollViewer and I found a sample, but when I try to add the class to the XAML file I get an error: Error 2 The type 'AniScrollViewer' was not found. Verify that you are not missing an assembly reference and that all referenced assemblies have been built. this is the c...

WPF - mouse wheel not working when over ScrollViewer's child controls

I was kind of expecting my ScrollViewer's child controls to hand the MouseWheel events back up the the ScrollViewer automatically, and that's not the case. I have a ScrollViewer with a ListBox in it. If I manually resize the width of the ListBox to be less than the ScrollViewer, the MouseWheel works on all of the ScrollViewer but has n...

WPF: How to make canvas auto-resize?

I would like my canvas to automatically resize to the size of its items, so that the ScrollViewer scroll bars have the correct range. Can this be done in XAML? <ScrollViewer HorizontalScrollBarVisibility="Auto" x:Name="_scrollViewer"> <Grid x:Name ="_canvasGrid" Background="Yellow"> <Canvas x:Name="_canvas" HorizontalAlignme...

ScrollViewer around a WrapPanel: scroll buttons at top of window and no scroll bar

I've got a wrapPanel surounded by a ScrollViewer. The WrapPanel can hold 1-n images. When the number of images in the wrap panel is more than the ScrollViewer can show, the ScrollViewer shows its up/down scroll buttons. But the buttons are both at the top of the scroll bar, and I get no scroll bar. This is shows in the picture, highl...

Wrapping images in ListBox using WrapPanel and ScrollViewer, Selected Items disappear!!

I'm using a ListBox to display a horizontal display of 800 thumbnails, but only 6 at a time (depending on screen resolution), I want to move through the images using buttons either side of the list. I currently have this working, but when I change the SelectedItem of the listbox to next/previous thumbnail the ScrollViewer doesn't autom...

Silverlight: Cannot manage to get ScrollViewer and WrapPanel to work together

Hi, I'm using a WrapPanel to format some text. During runtime I add TextBlocks and StackPanels as Children. Obviously I need a scrollbar depending on the data size. Searching the web I found multiple answers which all propose to put a ScrollViewer around the WrapPanel. That makes sense to me, but I cannot get it to work. Here's my code:...

WPF Child element of a Canvas outside of rect bounds

I am creating a control where I am simulating a popup by using a canvas that contains a textbox and a grid container. The size of the canvas gets set to the size of the textbox and the textbox is positioned at 0,0 within the canvas. The Grid container is positoned at the y coordinate of the textbox and its visibility is set to Collapsed....

how to rotate/scroll picker with a flick in scrollview in iphone sdk 3.0 ?

I have a pickerView in a scollView, which would rotate if i sweep across it in sdk 2.2.1 according to http://discussions.apple.com/thread.jspa?messageID=8284448 but when i changed the target to sdk 3.0, it is only responding to tapping and rotate 1 row at a time. but for many values that way is tiresome. can anyone help me here to rota...

ScrollViewer ContentScroll is missing

hi, my ScrollViewer doesn't work. scrolling isn't possible. <ScrollViewer> <StackPanel> <ListView> </ListView> <Grid> </Grid> <ListView> </ListView> </StackPanel> </ScrollViewer> i have tried different possibilities with setting of height (for ScrollViewer and StackPanel). how to scroll the content ? EDIT: Vertica...

ScrollViewer not showing up properly?

Does anyone know what's wrong with my code: <Border Background="AliceBlue" BorderThickness="2"> <Grid Name="MainGrid" Background="DarkGray" > <Grid.RowDefinitions> <RowDefinition Height="0.02*"/> <RowDefinition Height="0.07*"/> <RowDefinition Height="0.63*"/> <RowDefinition Hei...

How can I make the Silverlight ScrollViewer scroll to show a child control with focus?

I have a ScrollViewer which contains a Grid with multiple controls in it. The user can tab through the controls, but eventually they tab to a control that isn't in view - so they have to manully scroll to make the control visible again. Is there any way to make the ScrollViewer scroll automatically so that the focussed control is always...

WPF - ScrollViewer will not scroll when ScrollToHorizontalOffset() is called

I have a Scrollviewer inside a TabControl, and for some reason when you change tabs my ScrollViewer jumps to HorizontalOffset of 12. My ScrollViewer, among other things has a ListView inside it with an unrestricted height. It's a strange layout, but everything inside the scroller had to be printable so I couldn't easily allow the ListV...

ScrollViewer not scrolling....

The scrollviewer below does not work. I tried everything I could find on this site and beyond: embedding the scrollviewer in an Grid, embedding the ScrollViewer's children in a grid, embedding the Scrollviewer in a StackPanel with fixed height, setting/binding the height of the scrollviewer, all to no avail... Who shows me the way back t...

Odd Border effect on ItemsControl with ScrollViewer in ControlTemplate

I've got an ItemsControl (in a DockPanel with other stuff) which has a ControlTemplate to provide a ScrollViewer because the items won't fit on the screen. With the given config, I get a strange double-border top and bottom. It looks like a grey line above the top line and another below the bottom line. The sides are unaffected. I ge...

WPF ListView still reserving space when collapsed

I have a WPF ListView within a ScrollViewer. I need to collapse the ListView and I am trying withthis code (pretty striaghtoforward): this.myListView.Visibility = Visibility.Collapsed; Problem is the ListView seems to be reserving the space even when collapsed - it disappears but the ScrollViewer doesn't accordingly resize. Anything...

How to increase scrollbar width in WPF ScrollViewer?

I am wokring on a touch screen on a small device and the custom width of the scroll-bar is no good as one of my requirements is that everything needs to be doable by finger gestures. How can I set the width of the WPF ScrollViewer scrollbar? Note that I don't wanna change the width of all the scrollbars on the device (doable through wi...