Share via


HPageBreak.DragOff Method

Drags a page break out of the print area.

Namespace:  Microsoft.Office.Interop.Excel
Assembly:  Microsoft.Office.Interop.Excel (in Microsoft.Office.Interop.Excel.dll)

Syntax

'Declaration
Sub DragOff ( _
    Direction As XlDirection, _
    RegionIndex As Integer _
)
'Usage
Dim instance As HPageBreak
Dim Direction As XlDirection
Dim RegionIndex As Integer

instance.DragOff(Direction, RegionIndex)
void DragOff(
    XlDirection Direction,
    int RegionIndex
)

Parameters

  • RegionIndex
    Type: System.Int32

    Required Integer. The print-area region index for the page break (the region where the mouse pointer is located when the mouse button is pressed if the user drags the page break). If the print area is contiguous, there’s only one print region. If the print area is noncontiguous, there’s more than one print region.

Remarks

This method exists primarily for the macro recorder. You can use the Delete method to delete a page break programmatically.

See Also

Reference

HPageBreak Interface

HPageBreak Members

Microsoft.Office.Interop.Excel Namespace