使用itextsharp从PDF文件中提取文本时出现错误“无法找到图像数据或EI”
我已经放置了我的代码和示例文件。请做好必要的事。
Dim simg,tmp,sImgPDFLst As String
simg = AOTD_SU_20131118_006.pdf
Dim reader As iTextSharp.text.pdf.PdfReader = Nothing
tmp = pdf.parser.PdfTextExtractor.GetTextFromPage(reader, 1, New pdf.parser.SimpleTextExtractionStrategy())
If tmp.Length = 0 Then
sImgPDFLst = "Following files are IMAGE PDF"
End If
reader.Dispose()
reader.Close()
reader = Nothing
链接:https://drive.google.com/file/d/0B_nzYHWVJJ7KbnFSRWx5ZVNpSkk/edit?usp=sharing