I am using MuPDF Library to read a PDF inside application. For a normal pdf, It is working fine for me. But for a password protected pdf, I couldn't open my pdf. How to make it possible? Anyone can help me? I used sample code:
private MuPDFCore openFile(String path) {
int lastSlashPos = path.lastIndexOf('/');
mFilePath = lastSlashPos == -1 ? path : path.substring(lastSlashPos + 1);
try {
core = new MuPDFCore(mContext, path);
} catch (Exception e) {
Log.e(tag, "Error: "+e.getMessage());
return null;
}
return core;
}
在 mupdf Android 示例代码中查看 MuPDFActivity.java 中的requestPassword
(以及对它的调用)。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.