PDF Opening Issues

Fix a Drag-and-Drop PDF Upload That Acrobat Reader Cannot Open

Elise WilliamsElise Williams Nov 19, 2026 868 views

Question details

Determine why a PDF uploaded by drag and drop cannot be opened, while the same PDF uploaded through a file dialog works.

Fix a Drag-and-Drop PDF Upload That Acrobat Reader Cannot Open
Product
Adobe Acrobat Reader and the PDF upload application
Device & OS
not provided
Scenario
The same PDF is uploaded using a file dialog and a drag-and-drop interface, then stored for later opening.
Observed behavior
The stored files have matching lengths, but the drag-and-drop version has different bytes near the end and cannot be opened in Acrobat Reader.
Before you start

Keep the original PDF and both uploaded versions available for comparison. Use a binary or hex viewer and a SHA-256 tool to inspect their bytes and checksums.

Solution 1Recommended

Trace and correct the drag-and-drop binary upload

Use this method to find where the drag-and-drop path changes PDF bytes and ensure the stored file matches the original.

Matching file lengths do not prove that the contents are identical. An extra character or altered bytes near the final %%EOF marker can indicate that the drag-and-drop or storage path has modified the file.

1
Compare the uploaded files

Open the original, file-dialog upload, and drag-and-drop upload in a hex viewer. Compare the bytes near the final %%EOF marker and calculate a SHA-256 checksum for each file.

2
Inspect the drop handler

In the application's drop event handler, inspect the File from dataTransfer.files. Upload the File as binary data, such as by appending it to FormData, rather than converting its contents to a text string.

3
Check server and database handling

Inspect the server's multipart file handling and database write and read code. Store the uploaded bytes in a binary field, and avoid text encoding or unnecessary binary-to-string conversions.

4
Verify each stage

Calculate SHA-256 checksums for the original file, the received file before storage, and the retrieved file. Fix the first stage where the checksum changes, then upload the original again through drag and drop.

5
Test the corrected upload

Open the newly retrieved PDF in Acrobat Reader and confirm that its checksum matches the original file.

Trace and correct the drag-and-drop binary upload
Check the bytes before editing the file: Whitespace may follow a PDF's final %%EOF marker. Do not assume that deleting a trailing character will repair the file; compare it with the original and correct the upload or storage process.
Free Microsoft Office alternative

Open PDF Files and Office Documents with WPS Office

WPS Office is a free, lightweight alternative for viewing PDFs and working with Office documents in a familiar interface. Its format compatibility helps make the move from Microsoft Office easier, though it cannot fix corruption in your upload pipeline.

Open PDF files to check whether a retrieved document is readableCompatible with Microsoft Office formats including DOCX, XLSX, and PPTXFamiliar interface for a straightforward transition from Microsoft OfficeFree, lightweight tools for everyday document work
microsoft office alternative - wps office

Frequently Asked Questions

Can two PDF files have the same size but different contents?

Yes. Bytes can be replaced without changing the file length. Calculate a SHA-256 checksum for each file or compare them in a hex viewer to detect differences.

Does any character after %%EOF mean a PDF is corrupt?

Not necessarily. Whitespace may follow the final %%EOF marker, and viewer tolerance can vary. Compare the ending with the original PDF and investigate any unexpected changes.

How should a drag-and-drop handler send a PDF?

Get the File from dataTransfer.files in the drop event and append it to FormData, or otherwise send its bytes as binary data. Avoid reading the PDF as text before uploading it.

How can I tell whether the database changed the PDF?

Calculate a SHA-256 checksum immediately before the database write and again after reading the file back. If they differ, inspect the binary field and any encoding or conversion in the write and read paths.

Can WPS Office repair the drag-and-drop upload?

WPS Office can open a readable PDF, but it cannot correct changes made by an application's upload or database code. Fix the binary handling and upload the original PDF again.