[Hint] How did I fix my ODT file

Discuss the word processor

Re: [Hint] How did I fix my ODT file

Postby acknak » Thu Dec 09, 2010 3:05 am

It's very hard to do anything but guess without having the actual (.odt) file to look at. I'm sure if you can attach it here, or upload it somewhere else and give us a link, that someone can take a look and see if anything can be recovered.

You can use the "Upload Attachment" link (below the message entry area after you click "POST REPLY"). [Forum] How to attach a document here
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby garbledtext » Thu Dec 09, 2010 8:36 pm

Hi acknak.

Thanks for your quick reply. I will attach the troubled document.

I read on another forum that images in OOo are by default linked rather than embedded when pasted into a document. Not realizing this, I deleted the image that I had pasted into this document off the hard drive and I think that's what caused this file to go hay-wire.
Attachments
fix.odt
This is the file that has garbled text in the content.xml
(57.51 KiB) Downloaded 255 times
OOo 2.4.1 on Windows XP SP2
garbledtext
 
Posts: 2
Joined: Thu Dec 09, 2010 1:08 am

Re: [Hint] How did I fix my ODT file

Postby acknak » Thu Dec 09, 2010 10:19 pm

Sorry, I don't know of anything that can be done with it. This type of damage is new to me; it looks like some binary data was saved in the document archive in place of the document content. Very strange.

There is an intact image in the file, some kind of process flowchart. That can be recovered easily, but I presume that you still have the original image as a separate file.
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby RoryOF » Thu Dec 09, 2010 10:25 pm

I could get nothing from it. I also looked to see if content.xml was (incorrectly ) some form of archive, but again, nothing.
Apache OpenOffice 4.1.7 on Xubuntu 18.04.3 (mostly 64 bit version) and very infrequently on Win2K/XP
User avatar
RoryOF
Moderator
 
Posts: 29759
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: [Hint] How did I fix my ODT file

Postby EsTr3ToR » Tue Feb 01, 2011 8:50 pm

Hi,

Could you guys check on this file?
Tried several ways, none seems to be working.
I would be very thankfull :super:
http://www.mediafire.com/?b53evbgbn8zxz3g
OpenOffice 3.1 on Windows 7x64
EsTr3ToR
 
Posts: 2
Joined: Tue Feb 01, 2011 8:43 pm

Re: [Hint] How did I fix my ODT file

Postby acknak » Tue Feb 01, 2011 9:17 pm

Try this one: uk op 6_recovered.ods

Let me know when you have it and I'll remove the link+file.
Last edited by acknak on Wed Feb 02, 2011 12:45 am, edited 1 time in total.
Reason: removed sample file
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby EsTr3ToR » Tue Feb 01, 2011 11:27 pm

Works! Thanks a bunch!
What was the problem? Invalid characters or style errors?
OpenOffice 3.1 on Windows 7x64
EsTr3ToR
 
Posts: 2
Joined: Tue Feb 01, 2011 8:43 pm

Re: [Hint] How did I fix my ODT file

Postby acknak » Wed Feb 02, 2011 1:10 am

Yes; there was a single invalid character in the content.xml.

All I had to do was pass the content.xml file through an xml syntax checker ("xmllint") which found that In one attribute "office:value-type="float", the dash character was replaced with a Ctrl+A (0x01) character.

Once I replaced the invalid character with the hyphen, and replaced the content.xml in the archive, the document opened fine.
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby omega_x » Thu Feb 10, 2011 7:49 pm

Could anyone help me repair this file?
I already tried to delete all data between "<office:automatic-styles>" and "</office:automatic-styles>" without any results.
A lot of thanks in advance.

 Edit: Hagar (Moderator): file removed. 
Open Office 3.2.1
Windows 7
omega_x
 
Posts: 3
Joined: Thu Feb 10, 2011 7:25 pm

Re: [Hint] How did I fix my ODT file

Postby Hagar Delest » Thu Feb 10, 2011 11:46 pm

I've sent you a PM with the recovered file. Since there are some personal data inside, I've removed it from your post.

I think that the file has been cropped, that is the end of the content.xml file has not been correctly written. So by adding the tags that close the document, I've saved what was before the "cut". Don't know how much I've recovered.
AOO 4.1.7 on Xubuntu 19.10 and 4.1.5 on Windows 10 (with winPenPack port).
User avatar
Hagar Delest
Moderator
 
Posts: 28590
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: [Hint] How did I fix my ODT file

Postby omega_x » Thu Feb 10, 2011 11:49 pm

Thank you very much!!
Open Office 3.2.1
Windows 7
omega_x
 
Posts: 3
Joined: Thu Feb 10, 2011 7:25 pm

Re: [Hint] How did I fix my ODT file

Postby Hagar Delest » Fri Feb 11, 2011 12:05 am

Just for the record, do you have suffered a heavy data loss or just some bits?
AOO 4.1.7 on Xubuntu 19.10 and 4.1.5 on Windows 10 (with winPenPack port).
User avatar
Hagar Delest
Moderator
 
Posts: 28590
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: [Hint] How did I fix my ODT file

Postby omega_x » Fri Feb 11, 2011 7:59 am

No, the data is pretty much intact.
Open Office 3.2.1
Windows 7
omega_x
 
Posts: 3
Joined: Thu Feb 10, 2011 7:25 pm

Re: [Hint] How did I fix my ODT file

Postby abe » Fri Feb 18, 2011 6:30 pm

i am having tough time recovering attached file. I did file recovery using Recuva after accidental mess up deleting files. i have few about 30 files like this state. If somebody can help on this and guide how i might recover rest of the file using same pattern would be much appreciated
Attachments
vitamins.odt
(23.12 KiB) Downloaded 195 times
OpenOffice.org 3 windows xp
abe
 
Posts: 1
Joined: Fri Feb 18, 2011 6:26 pm

Re: [Hint] How did I fix my ODT file

Postby acknak » Fri Feb 18, 2011 8:32 pm

Sorry, but the file you attached does not contain the document's data. It seems to contain random information from other files on the system.

There's nothing there to recover.
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby mac1 » Fri Feb 18, 2011 10:09 pm

Similar but different . Did a search ref above if this is wrong place let me know and I'll change :(
I don't get the above error code.
When I try to open the hour glass shows up , have it left run several hours with no joy, the task manager reports running ( no non_ responding report). When I terminate the process with the task manger then this file shows up .~lock.simplification of meshes.odt# Have deleted all my OO programs via the add and remove route, including those left behind form previous installs, cleaned the registry, ran virus check and then installed latest OO 3.3 ( The problem file is a 3.2 version). The results are the same. Have not tried any fixes ref above. Should I try the above or should I attach file. It is large 1.5 MB??
Ran the validator and it showed 11 warnings and this error;
This file is NOT valid

Result details:

upload:///simplification of meshes.odt/META-INF/manifest.xml[2,88]:Error:element "manifest:manifest" is missing "version" attribute
upload:///simplification of meshes.odt:Info:Generator: OpenOffice.org/3.2$Win32 OpenOffice.org_project/320m18$Build-9502
I don't have a manifest .xml but have a mainfest.rdf.
I extracted the files by rename of my file from xxxx.odt to xxxx.zip and then extracted and then changed back for the above test :evil:
OOo 3.2+, Windows Xp Pro sp3 P4 3.2Ghz, 4Gb memory, 600 GB hard disk
mac1
 
Posts: 9
Joined: Tue Mar 09, 2010 6:58 pm

Re: [Hint] How did I fix my ODT file

Postby acknak » Sat Feb 19, 2011 1:45 am

It's probably simplest to make the file available so others can try it--if the file works for others, then we'll know it's not a problem with the file. The validator sometimes complains about things that OOo doesn't care about.

You can use the "Upload Attachment" link (below the message entry area after you click "POST REPLY"). [Forum] How to attach a document here

Note: large documents have to be shared through some other means; there are suggestions in the link above.
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby mac1 » Sat Feb 19, 2011 2:31 am

Up date;
ajut001 determined what to do but I did change the flow a little:
1) Unzip the xxxxxx.zip ( the original xxxxx.odt OO with extension change) . I use Zip Genius for this. ;
2) Open the xml file using the xml NotePad 2007 I downloaded form Microsoft. The program has a tree capability so search for the target to delete is not required because it appears in the top level of the hierarchy;
2) Delete target and save file;
4) Select this save file and the others extracted from the xxxxxx.zip and use Zip Genius to make a archive;
5) Save archive and change file name back to xxxxxxx.odt
File now opens OK. It appears the number of jpg's I had in th file were causing the problem. File must be re- formatted and pictures re-inserted.
How does one avoid this goat rope in the future
I was very close to submitting this as a WIKI and these problems are not acceptable.
OOo 3.2+, Windows Xp Pro sp3 P4 3.2Ghz, 4Gb memory, 600 GB hard disk
mac1
 
Posts: 9
Joined: Tue Mar 09, 2010 6:58 pm

Re: [Hint] How did I fix my ODT file

Postby chariteb » Sun Jun 05, 2011 8:24 pm

Hello,

Can someone fix my file, 6 months of work is in this file.

It's a spreadsheet and the error is:

Error in subdocument content.xml on position 2,528190 (row,column).

I've tried every tip in this forum, still Ooo refuses to read.

http://www.mediafire.com/?7oz2hf5f3skf5hn

Regards,

Boudewijn
OpenOffice 3.3.0 on Windows Vista / LibreOffice 3.4.0 on Windows Vista / LibreOffice 3.3.0 on openSUSE
chariteb
 
Posts: 2
Joined: Sun Jun 05, 2011 8:11 pm

Re: [Hint] How did I fix my ODT file

Postby acknak » Sun Jun 05, 2011 9:43 pm

Try this one: Dagboeken 2011_recovered.ods

Do remember to make regular backup copies of important documents. Every time you open a document you're taking a chance that it will be corrupted or lost. Your only real protection is to make backup copies regularly, using different file names.
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby chariteb » Mon Jun 06, 2011 8:36 pm

Thanks it worked,

and I will start immediate with a daily backup system. I had but didn't installed it on my new file server yet.

I don't know why but I opened this file in Libre Office 3.4.0 did some work in it saved it, got some error, saved it again without any warning now so I assumed it was ok. A few days later found this error.

What was wrong with the file because I could not find the "real" error. The validator http://tools.services.openoffice.org/odfvalidator/ of Ooo gave me some errors in some columns but still couldn't open it after fixing most of them.

Which tool you used to edit the xml file, notepad++ was terribly slow editing such a big file.

Regards,
Boudewijn
OpenOffice 3.3.0 on Windows Vista / LibreOffice 3.4.0 on Windows Vista / LibreOffice 3.3.0 on openSUSE
chariteb
 
Posts: 2
Joined: Sun Jun 05, 2011 8:11 pm

Re: [Hint] How did I fix my ODT file

Postby Hagar Delest » Mon Jun 06, 2011 9:00 pm

Don't know for acknak but personally, I use XML Copy Editor (both on Windows and GNU/Linux) and it works fine, it can check the XML structure directly so you can undo modifications if you introduce errors.
AOO 4.1.7 on Xubuntu 19.10 and 4.1.5 on Windows 10 (with winPenPack port).
User avatar
Hagar Delest
Moderator
 
Posts: 28590
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: [Hint] How did I fix my ODT file

Postby acknak » Tue Jun 07, 2011 1:18 am

Any software that I've ever tried for working with ODF's xml has been very unpleasant--either too slow or somehow unable to cope with OOo's "all in one line" xml, or an xml file that OOo has made a hash of.

I generally use two command-line utilities and a plain text editor. Emacs is my text editor; xmlindent is handy to re-format OOo's all-in-one-line xml, and xmllint tries to check an xml file for errors.

In this case, the problem turned out to be very easy to deal with.

Xmllint gave me this output:
    $ xmlindent -i2 content.xml | xmllint -noout -
    -:4725: parser error : Attribute table:end-cell-address redefined
    -:4725: parser error : Attribute table:end-x redefined
    -:4725: parser error : Attribute table:end-y redefined
    -:4725: parser error : Attribute draw:z-index redefined
Line 4725 looks like this:
    <table:table-cell table:end-cell-address="&apos;Kasboek per dag&apos;.J42" table:end-x="0.926cm" table:end-y="0.417cm" draw:z-index="0" table:end-cell-address="&apos;Kasboek per dag&apos;.J40" table:end-x="0.476cm" table:end-y="0.365cm" draw:z-index="0" table:style-name="ce251" office:value-type="string" table:number-columns-spanned="6" table:number-rows-spanned="2">
You can see that four of the attributes appear twice in the same xml element. That's not allowed, so the xml is not valid and won't be loaded.

I used a text editor to remove the first set of attribute values, leaving only the second set, shown in blue. I then updated the content.xml file in your document with the modified one and that opened without errors in Calc.
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby n1120ec » Tue Oct 11, 2011 7:56 pm

I don't know if you guys are still helping out people with file errors, I've tried all the things listed and at wits end right now. Wondering if anyone can help out with a file. I've posted it http://www.mediafire.com/file/4ou69opcq ... orynew.ods

Thank you for the help, I used ALZIP to unzip the file so I will upload that content.xml http://www.mediafire.com/?qd24fb2u18d98p6
Last edited by n1120ec on Tue Oct 11, 2011 8:57 pm, edited 1 time in total.
Openoffice 3.3 Windows 7
n1120ec
 
Posts: 2
Joined: Tue Oct 11, 2011 7:37 pm

Re: [Hint] How did I fix my ODT file

Postby floris v » Tue Oct 11, 2011 8:33 pm

There's a problem with your file: I couldn't extract content.xml so I downloaded a demo of ZipRepair Pro to see if I could repair it and it reports that the filesize of the archive seems to be incorrect. To be sure, a compression of 95% seems a bit much. I'm afraid that part of the file got truncated and that content.xml can't be recovered.
AOO 4.1.6 op Linux Mint
If your problem has been solved or your question has been answered, please edit the first post in this thread and add [Solved] to the title bar.
Nederlandstalig forum
User avatar
floris v
Moderator
 
Posts: 4168
Joined: Wed Nov 28, 2007 1:21 pm
Location: Netherlands

Re: [Hint] How did I fix my ODT file

Postby Hagar Delest » Tue Oct 11, 2011 8:50 pm

I managed to extract the content.xml file (but having the CRC error). Managed to get a part of it in vi but no way to make it displayed in Gedit or XML Copy Editor so not sure it can be recovered.
AOO 4.1.7 on Xubuntu 19.10 and 4.1.5 on Windows 10 (with winPenPack port).
User avatar
Hagar Delest
Moderator
 
Posts: 28590
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: [Hint] How did I fix my ODT file

Postby n1120ec » Tue Oct 11, 2011 9:15 pm

Do you guys think if I use Sysinfo tools for Calc recovery to fix, if it would work???? And thank you guys for all the help
Openoffice 3.3 Windows 7
n1120ec
 
Posts: 2
Joined: Tue Oct 11, 2011 7:37 pm

Re: [Hint] How did I fix my ODT file

Postby TheGurkha » Tue Oct 11, 2011 10:10 pm

n1120ec wrote:Do you guys think if I use Sysinfo tools for Calc recovery to fix, if it would work? And thank you guys for all the help


Sadly no.
Ubuntu 14.10 Utopic Unicorn, LibreOffice Version: 4.3.3.2
Gurkha Welfare Trust
User avatar
TheGurkha
Volunteer
 
Posts: 6482
Joined: Thu Mar 13, 2008 12:13 pm
Location: North Wales, UK.

Re: [Hint] How did I fix my ODT file

Postby acknak » Tue Oct 11, 2011 10:30 pm

The text in the content.xml file is very badly garbled. I very much doubt that any usable data can be recovered from it, by any tool. The only solution is a backup file.
AOO4/LO5 • Linux • Fedora 23
User avatar
acknak
Moderator
 
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: [Hint] How did I fix my ODT file

Postby Bill » Wed Oct 12, 2011 12:46 am

Maybe you can recover a previous version of the file:

Previous versions of files: frequently asked questions
Bill
Volunteer
 
Posts: 7392
Joined: Sat Nov 24, 2007 6:48 am

PreviousNext

Return to Writer

Who is online

Users browsing this forum: MSN [Bot] and 18 guests