Comments (4)
I noticed that when I open the file, add one character to a field, save it and reprocess it, it gives no error?
from pdfpig.
Anything I can provide in order to support you as efficient as possible?
This issue is making my current tool non-functional because 5% of the PDF files cannot be processed.
from pdfpig.
Unfortunately this error can be due to basically any unexpected formatting in the source file. Without the source file it is very difficult to tell.
The error message suggests the error is happening when trying to find the information near the end of the document which looks like:
xref
0 103
0000000000 65535 f
0000058002 00000 n
0000000019 00000 n
0000001903 00000 n
0000058273 00000 n
...
It might be possible to get more information about the error locally by debugging the PdfPig code. You can clone this repository and locally set the version of .NET you have available with this script https://github.com/UglyToad/PdfPig/blob/master/tools/set-dotnet-version.ps1
Then you can load the file in a test and see what is going wrong: https://github.com/UglyToad/PdfPig/blob/master/src/UglyToad.PdfPig.Tests/Integration/LocalTests.cs
from pdfpig.
Hello @EliotJones,
Thanks for the feedback.
I removed the Nuget package and cloned the repository.
When I run my code I see the following:
- PdfTokenScanner: Line: 241 : Debug.WriteLine("Found more than 1 token in an object.");
- The exception is thrown by: CrossReferenceParser (line 164:
if (!TryParseCrossReferenceStream(previousCrossReferenceLocation, pdfScanner, null, out var tablePart))
{
if (!TryBruteForceXrefTableLocate(bytes, previousCrossReferenceLocation, out var actualOffset))
{
//This is the point when it gives the error
throw new PdfDocumentFormatException();
}
previousCrossReferenceLocation = actualOffset;
missedAttempts++;
continue;
}
from pdfpig.
Related Issues (20)
- PDF linearization
- When a get textblock from a PDF vary depending on the operating system HOT 6
- New Nuget package release for PDF Pig HOT 6
- XYLeaf.GetLines collect lines not robust enough HOT 18
- Extracting lines HOT 3
- Copy existing page to PdfDocumentBuilder without it's text HOT 1
- TryGetForm does not support field partial names with a "." HOT 5
- Support p7m signed PDFs
- Why GlyphRectangle bounding box not correct for letter g?
- Errors in examples on "readme.md" ? HOT 1
- Allow reading orders dectors to support any class that has a bounding box/PdfRectangle HOT 1
- ArgumentOutOfRangeException when reading a document HOT 7
- Add image to PDF with different coordinate origin
- Using DuplicateOverlappingTextProcessor in HOcrTextExporter
- Populate data catalog info without reading the rest of the pdf
- Read document structure and apply PDF accessibility tag? HOT 1
- "Object reference not set to an instance of an object." HOT 6
- PdfDocumentBuilder creates broken annotation elements when copying pages from specific source PDFs HOT 3
- IndexOutOfRangeException in ByteEncodingCMapTable.CharacterCodeToGlyphIndex Method HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pdfpig.