Viscomsoft UWP PDF Viewer SDK

PDFDisplayManager.PageChanged Event

Description

Occurs when the Page has changed. 

Syntax

public event PageChanged;

No Parameters

 

Example

[C# Syntax] 
using Viscomsoft.UWP.PDFViewerSDK;

private async void open(StorageFile file)
  {

    DocumentFactory factory = new DocumentFactory();

    IDocument doc = factory.CreateDocument(file.Name);

    bool opened = await doc.OpenAsync(file);

    _pdfDisplayManager = new PDFDisplayManager();

    _pdfDisplayManager.Width = (int)Window.Current.Bounds.Width;

    _pdfDisplayManager.Height = (int)Window.Current.Bounds.Height;

    _pdfDisplayManager.Document = doc;

    _pdfDisplayManager.PageChanged += PDFDisplayManager_PageChanged;

    _pdfDisplayManager.GotoPage(1);

    uiViewPanel.Child = createScrollViewControl();
 

  }
 

  void PDFDisplayManager_PageChanged(object sender, EventArgs e)
  {
     MessageDialog dlg = new MessageDialog("page changed");
     dlg.ShowAsync();
  }