This project has moved and is read-only. For the latest updates, please go here.

Removing comments causes errors when opening excel file

Nov 22, 2012 at 6:22 PM

I am using EPPlus to add/remove comments to/from an excel file after processing.

When I try to open the file after it has been processed I get the following error:

"Excel found unreadable content in 'xxxx.xlsx'. Do you want to recover the contents..........."

After clicking on "Yes", this error is followed by the error:

"Removed Part: /xl/comments1.xml part with XML error.  (Comments) Incorrect document syntax. Line 63, column 14."

The file still opens but these errors cause all comments on the file to disappear. This only seems to happen after a certain number of comments have been removed by the EPPlus library.

Has anyone encountered this problem before or know why this may be happening?