FlexGrid for WinForms | ComponentOne
C1.Win.C1FlexGrid Namespace / C1FlexGridBase Class / BeforePageBreak Event

In This Topic
    BeforePageBreak Event (C1FlexGridBase)
    In This Topic
    Fires while the control is being printed to provide control over page breaks.
    Syntax
    'Declaration
     
    
    Public Event BeforePageBreak As RowColEventHandler
    public event RowColEventHandler BeforePageBreak
    Event Data

    The event handler receives an argument of type RowColEventArgs containing data related to this event. The following RowColEventArgs properties provide information specific to this event.

    PropertyDescription
    Gets or sets a value indicating whether the operation should be canceled.  
    Gets the index of the column that caused the event.  
    Gets the index of the row that caused the event.  
    Remarks

    This event is fired while the control is being printed with the PrintGrid(String,PrintGridFlags) method to provide control over page breaks.

    Set the Cancel parameter to true to indicate that the given Row should not be printed at the top of a page. In this case, the control will move the break point up and fire the event again until it finds a valid break point. Note that you can only prevent page breaks, not force them.

    See Also