iText操作错误:PdfReader not opened with owner password
2016-06-16 08:29
381 查看
Caused by: com.itextpdf.text.exceptions.BadPasswordException: PdfReader not opened with owner password
at com.itextpdf.text.pdf.PdfStamperImp.<init>(PdfStamperImp.java:109)
at com.itextpdf.text.pdf.PdfStamper.<init>(PdfStamper.java:94)
at com.platform.base.util.PDFFormUtil.fillPDFForm(PDFFormUtil.java:93)
... 1 more
解决方法:
PdfReader reader= new PdfReader(templete);
Field f = PdfReader.class.getDeclaredField("ownerPasswordUsed");
f.setAccessible(true);
f.set(reader, Boolean.TRUE);
相关文章推荐
- itext报错PdfReader not opened with owner password
- itext PDF 分页 并 解决PdfReader not opened with owner password
- iText创建pdf文件里,解决ClassNotFoundException错误
- 解决iText 5.0.1生成pdf,加入iTextAsian.jar 出现异常 Font 'STSong-Light' with 'UniGB-UCS2-H' is not recognized.的
- SharePoint创建web application出现“The password supplied with the username was not correct. Verify that it was entered correctly and try again.”错误
- 用itextpdf导出pdf时报错: Font 'STSong-Light' with 'UniCNS-UCS2-H' is not recognized.
- SharePoint创建web application出现“The password supplied with the username was not correct”错误的解决方法
- 解决iText 5.0.6生成pdf,出现异常 Font 'STSong-Light' with 'UniGB-UCS2-H' is not recognized.的异常
- C#数据库操作错误:There is already an open DataReader associated with this Connection which must be closed..
- itext生成pdf加了iTextAsian.jar还是报“Font 'STSong-Light' with 'UniGB-UCS2-H' is not re“
- iText 5.0.1生成pdf,加入iTextAsian.jar 出现异常 Font 'STSong-Light' with 'UniGB-UCS2-H' is not recognized.的问题
- itext生成PDF文件报错“Font 'STSong-Light' with 'UniGB-UCS2-H' is not recognized.”
- iText操作PDF读取JPEG图片ArrayIndexOutOfBoundsException异常
- 解决jasperreport pdf导出错误Could not load the following font问题
- MYSQL操作中错误The user specified as a definer ('root'@'%') does not exist的解决
- Java使用iText实现对PDF文件的操作
- Type 'com.itextpdf.text.List' does not have type parameter
- iText操作PDF学习(二)
- 解决android studio错误 --> Error:(1, 0) Plugin with id 'com.android.application' not found
- .py程序运行时,出现operands could not be broadcast together with shape (12,) (11,)错误