Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Could not find the startxref within the last 2048 characters. #816

Open
last-Programmer opened this issue Apr 5, 2024 · 2 comments
Open

Comments

@last-Programmer
Copy link

last-Programmer commented Apr 5, 2024

I am trying to open a pdf generated by crystal reports and it is giving the error

Could not find the startxref within the last 2048 characters.

We open number of pdfs generated by Crystal Reports and it all works fine. But with one specific report we are getting this error.

Unfortunately we are not able to get the pdf since it is a a step in a long process in production app.

The call stack shows this

at UglyToad.PdfPig.Parser.FileStructure.FileTrailerParser.GetStartXrefPosition(IInputBytes bytes, Int32 offsetFromEnd)
at UglyToad.PdfPig.Parser.FileStructure.FileTrailerParser.GetFirstCrossReferenceOffset(IInputBytes bytes, ISeekableTokenScanner scanner, Boolean isLenientParsing)
at UglyToad.PdfPig.Parser.PdfDocumentFactory.OpenDocument(IInputBytes inputBytes, ISeekableTokenScanner scanner, InternalParsingOptions parsingOptions)
at UglyToad.PdfPig.Parser.PdfDocumentFactory.Open(IInputBytes inputBytes, ParsingOptions options)

Is there a way to fix this issue.

Thank You very much in advance.

@BobLd
Copy link
Collaborator

BobLd commented Apr 5, 2024

@last-Programmer can you confirm you used the latest nightly build 0.1.9-alpha-20240402-f6292

@last-Programmer
Copy link
Author

@BobLd i will try the alpha version and update you. thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants