Skip to main content

RichEditControl.VisiblePagesChanged Event

Fires when RichEditControl starts or finishes displaying a document page.

Namespace: DevExpress.XtraRichEdit

Assembly: DevExpress.XtraRichEdit.v24.1.dll

NuGet Packages: DevExpress.Win.PivotGrid, DevExpress.Win.RichEdit, DevExpress.Win.TreeMap


public event EventHandler VisiblePagesChanged

Event Data

The VisiblePagesChanged event's data class is EventArgs.


The VisiblePagesChanged event occurs when a user scrolls or zooms the editing surface and changes visible pages.

The code sample below moves the caret position to the visible page’s start, so the vertical ruler is always visible:

void richEditControl_VisiblePagesChanged(object sender, EventArgs e)
  RichEditControl control = sender as RichEditControl;
  DocumentRange range = control.ActiveView.GetVisiblePagesRange();
  control.Document.CaretPosition = range.Start;
See Also