Unplanned
Last Updated: 14 May 2018 17:07 by Georgi
ADMIN
Georgi
Created on: 14 May 2018 17:04
Category: PDFViewer
Type: Bug Report
1
PdfViewer: Find Next command does not scroll to the matched text result when ScaleMode is FitToPage

This is reproducible when the matched result resides on different page. Workaround: You may subscribe to the RadFixedDocument.CaretPosition.PositionChanged event and implement the scroll logic. Subscribe to PdfViewer's DocumentChanged event first if the document is not loaded.

        private void CaretPosition_PositionChanged(object sender, EventArgs e)
        {
            Telerik.Windows.Documents.Fixed.Model.RadFixedPage currentPage = this.pdfViewer.Document.CaretPosition.Page;
            int pageIndex = this.pdfViewer.Document.Pages.IndexOf(currentPage);
            this.pdfViewer.GoToPage(pageIndex + 1);
        }

0 comments