打开PDF文件时,"PDFsharp无法处理Acrobat 6引入的PDF功能"错误 [英] 'PDFsharp cannot handle this PDF feature introduced with Acrobat 6' error while opening PDF file

查看:709
本文介绍了打开PDF文件时,"PDFsharp无法处理Acrobat 6引入的PDF功能"错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用PDFsharp(v1.32)合并多个PDF文件.我使用以下代码打开文档:

I use PDFsharp (v1.32) for merging several PDF files. I open documents using this code:

PdfDocument inputDocument = PdfReader.Open(pdfFilePath, PdfDocumentOpenMode.Import);

在打开一个文档(PDF版本1.5(Acrobat 6.x))时,我收到一个例外:

And while opening one document (with PDF version 1.5 (Acrobat 6.x)) I receive an exception:

PdfSharp.dll中发生了类型为'PdfSharp.Pdf.IO.PdfReaderException'的未处理异常 附加信息:无法处理iref流. PDFsharp的当前实现无法处理Acrobat 6引入的此PDF功能.

An unhandled exception of type 'PdfSharp.Pdf.IO.PdfReaderException' occurred in PdfSharp.dll Additional information: Cannot handle iref streams. The current implementation of PDFsharp cannot handle this PDF feature introduced with Acrobat 6.

我该怎么办?我需要合并所有文件,我不能只跳过它.我试图找到解决方案,但没有找到答案,或者只是来自PDFsharp Team的非常老的反馈,他们打算修复它".

What can I do with it? I need to merge all files, I cannot just skip it. I tried to find solution, but found not answered or just very old feedback from PDFsharp Team that they are going to "fix it".

推荐答案

使用2015年12月以后的PDFsharp 1.50 beta 3或更高版本.

Use PDFsharp 1.50 beta 3 from December 2015 or a newer version.

https://www.nuget.org/packages/PdfSharp/1.50. 4820-RC1
https://www.nuget.org/packages/PDFsharp-gdi/1.50 .4820-RC1
https://www.nuget.org/packages/PDFsharp-wpf/1.50 .4820-RC1

https://www.nuget.org/packages/PdfSharp/1.50.4820-RC1
https://www.nuget.org/packages/PDFsharp-gdi/1.50.4820-RC1
https://www.nuget.org/packages/PDFsharp-wpf/1.50.4820-RC1

https://github.com/empira/PDFsharp

这篇关于打开PDF文件时,"PDFsharp无法处理Acrobat 6引入的PDF功能"错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆