Share via


TextSelection.PageDown Method

Moves the active point a specified number of pages down in the document, scrolling the view.

Namespace:  EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

Syntax

'Declaration
Sub PageDown ( _
    Extend As Boolean, _
    Count As Integer _
)
void PageDown(
    bool Extend,
    int Count
)
void PageDown(
    [InAttribute] bool Extend, 
    [InAttribute] int Count
)
abstract PageDown : 
        Extend:bool * 
        Count:int -> unit 
function PageDown(
    Extend : boolean, 
    Count : int
)

Parameters

  • Extend
    Type: System.Boolean
    Optional. Determines whether the moved text is collapsed or not. The default is false.
  • Count
    Type: System.Int32
    Optional. Represents the number of pages to move down. The default value is 1.

Remarks

If the value of Extend is true, then the active end of the selected text is moved down Count number of pages. Otherwise, the selected text is collapsed and positioned Count pages down from the active end. If the end of the document is encountered before Count pages, then the position is left at the end of the document.

If Count is negative, then PageDown performs like the PageUp method.

Examples

Sub PageExample()
   ' Before running this example, open a text document.
   Dim objSel As TextSelection = DTE.ActiveDocument.Selection
   ' Go to first line in document and select it.
   objSel.GotoLine(1, True)
   objSel.PageDown(True, 2)
   objSel.PageUp(True, 2)
End Sub

.NET Framework Security

See Also

Reference

TextSelection Interface

EnvDTE Namespace