IViewScroller::ScrollViewportVerticallyByPage Method (ScrollDirection)
Scrolls the viewport vertically one page up or down.
Assembly: Microsoft.VisualStudio.Text.UI (in Microsoft.VisualStudio.Text.UI.dll)
Parameters
- direction
-
Type:
Microsoft.VisualStudio.Text.Editor::ScrollDirection
The direction in which to scroll.
Return Value
Type: System::Booleantrue if the view contains one or more fully visible lines prior to scrolling, otherwise false.
| Exception | Condition |
|---|---|
| ArgumentOutOfRangeException | direction is not a ScrollDirection. |
When paging down, this method scrolls the view so that the line below the last fully-visible line is even with the top of the view. When paging up, this method scrolls the view so that the line above the first fully visible line is even with or slightly above the bottom of the view. It may be shifted up to prevent a partially-visible line at the top of the view. If there are no fully-visible lines in the view because the view is too short, the view is scrolled by exactly the viewport height. The view cannot be scrolled so that there is a gap between the top of the view and the first line of text.