Enable scrollviewer to scroll for each element instead of default behavior
In my current project, I have a scroll viewer with multiple buttons listed. Instead of navigation, the standard scroll navigation buttons are used.
So what I want to achieve is when I click the navigation button (repeat button) the next button / item in the row appears.
With the default behavior, I can see the content appears slowly when I click the nav button.
When I click next or previous in the navigation, I want the next item in the row to appear instantly pending, for example 2 seconds before scrolling.
Inside the scrollviewer is the itemControl element, which contains a stack bar with custom buttons.
The scrollinger is on its turn, located in the grid.
Or is it a scrollviewer and not a way to move between elements in the panel stack using 2 navigation buttons?
EDIT: For some reason, logical scrolling doesn't seem to work anymore after applying the itemControl where the stack bar and datatemplate are located.
Thanks in advance! Jackz
This behavior is called logical scrolling. To enable it, you must place your ScrollViewer in a StackPanel and set the ScrollViewer "CanContentScroll" property to true.
Here you will find additional information.