<< Click to display table of contents >>


Returns index of page containing the specified place of the document.

function GetPageNo(RVData: TCustomRVData; ItemNo, OffsetInItem: Integer): Integer;


The parameters define a position in the source document,

RVData is a document/subdocument. It can be either RVData of the source TRichView control, or table cell, or RVData of a cell inplace editor.

For TRVPrint, the source TRichView control is a control assigned by AssignSource. For TRVReportHelper, the source TRichView control is RichView property.

ItemNo is the index of item in this RVData.

OffsetInItem is the position inside this item. For non-text items, 0 is a position before the item, 1 is a position after the item. For text items, offsets are counted from 1 (1 - before the first character, 2 - before the second character, ... Length+1 - after the last character).

Return value:

Index of the page for this position, from 1.

See also:


See also methods of TCustomRichView: