When I try to open the file, I get the error, “Read Error. Format error discovered in the file in sub-document content.xml at 2,33870(row,col).”
I have followed instructions from other threads and opened the content.xml in NotePad++ to examine the file, but I don’t see anything obvious.
I last edited the document 12/26/2020 and when I tried to open later that night, I got the above error.
Today I updated LibreOffice to version 7.0.3.1 (with timestamed backup extension this time!), but I’m not sure what version I was running prior.
Can someone please look at the file for me and provide some guidance? File is 22 KB.
Thank you in advance!
Can someone please look at the file for me and provide some guidance?
Pretty hard without the file - upload the file (the whole .ods
on not just the content.xml
)
> but I don't see anything obvious.
For me without an XML validator / format checker almost impossible (besides your daily business is XML
;-))
If you are familiar with an XML editor, you may fix it yourself based on a few hints. If not you will need help by somebody having your actual file at hand.
BTW: Has the file a curriculum containing episodes of beeing edited with MS software and/or savd to MS “file formats”?.
Concerning the “hints” see [Tutorial] Format error discovered in sub-document (View topic) • Apache OpenOffice Community Forum .
On the forum hosting this tutorial you find some contributors (myself among them) having fixed similar problems for users more than once. They also have PM/PN so that you can deliver and get back your file without exposing it to the public.
@Lupp, Thanks for the reply. I have not edited with or saved to MS file formats.
@anon73440385, Thanks for the reply. I would rather not post publicly if possible.
I would rather not post publicly if possible.
That’s OK - but then I can only tell how I do such stuff: I’m using Visual Studio Code (from https://code.visualstudio.com/ with 3 extensions installed:
-
XML
(v 0.14.0 - XML Language Support by Red Hat - Red Hat) -
XML Format
(v. 1.0.2 - Format XML documents - Mike Burgh) -
XML Tools
(v. 2.5.1 - XML Formatting, XQuery, … - Josh Johnson)
Performing the following (very high level - no details)
- Extract the
.ods
file into a directory - Load
.xml
files into Visual Studio Code application - Format the file using Format Tool
- Watch the errors found
- Double click the errors shown (which put the cursor to the affected location with the XML file
- Correct findings
- Save document
- Zip all file into document
ZIP managers like 7-Zip or Winzip can open OpenDocument files dierctly. They then show the wrapped-in files in a similar way as a file manager. From that presentation I open the content.xml with (in my case) notepad++ with the XML-tools extension (PrettyPrint with line breaks for formatting). Having found and fixed all errors, I can directly pack and save back to the archive (without leaving the software couple of the ZIP-manager and the notepad++). .
Done - so far.
The main part of all the action is, though:
To find XML-errors I use XML-tools again: Check XML syntax. Having found an error, it is not always quite simple to also find the “fixable cause”. But often it is very near to the position where an error was detected.
I would remind of the tutorial by Hagar Delest altready mentioned : [Tutorial] Format error discovered in sub-document (View topic) • Apache OpenOffice Community Forum.
Some posts added by John_Ha to that tutorial give interesting information, but teach again to extract wrapped-in files explicitly.
I would dissuade from this proceeding.
@Lupp and @anon73440385,
Thank you both for your help!
I was able to locate the code for sheet I last edited before the error occurred and delete just that sheet.
I was then able to open the spreadsheet with only the one sheet needing to be recreated.
You helped me avoid recreating 17 other sheets in the file!!!