pdf.js : How can we get the current pdf page number using pdf.js

纵然是瞬间 提交于 2019-12-23 02:42:36

问题


I want to get the current page number from pdf.js when user

Click's some Button.I'm not opening pdf file in iframe like that

Below link

using iframe

I'm using the pdf.js Directly From the GitHub Project

My Question is how can I get the Current page Number from

pdf.js


回答1:


PDFViewerApplication.pdfViewer.currentPageNumber is a getter and setter. Examples:

// Go to page 5
PDFViewerApplication.pdfViewer.currentPageNumber = 5;

// Move two pages forward
PDFViewerApplication.pdfViewer.currentPageNumber += 2;


来源:https://stackoverflow.com/questions/42439249/pdf-js-how-can-we-get-the-current-pdf-page-number-using-pdf-js

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!