Left, Top Properties Example

The following example checks the Left property setting for the current report. If the value is less than the minimum margin setting, the NextRecord and PrintSection properties are set to False (0). The section doesn't advance to the next record, and the next section isn't printed.

Sub Detail1_Format(Cancel As Integer, FormatCount As Integer)
Const conLeftMargin = 1880
' Don't advance to next record or print next section
' if Left property setting is less than 1880 twips.
    If Me.Left < conLeftMargin Then
        Me.NextRecord = False
        Me.PrintSection = False
    End If
End Sub