Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
The moose likes Java in General and the fly likes transform .odt to .txt in java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "transform .odt to .txt in java" Watch "transform .odt to .txt in java" New topic
Author

transform .odt to .txt in java

Eduardo Ewerton
Greenhorn

Joined: Jun 17, 2010
Posts: 2
Hello guys... i'm getting in java, and i have a litle problem.
I have to trasnform files .odt in files .txt in java.
If somebody have any idea... please post here!!

thank you all!
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19656
    
  18

You can start OpenOffice.org in server mode, then call its methods from Java. Check out the OOo documentation and tutorials on how to.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41173
    
  45
ODF files are ZIP files that contain various XML files; the actual content is in "content.xml". If the text is all you're interested in, unzip the file, parse the XML, and extract the pieces you're interested in (looking at it, it should be pretty obvious which ones those are).


Ping & DNS - my free Android networking tools app
 
jQuery in Action, 2nd edition
 
subject: transform .odt to .txt in java
 
Similar Threads
Java And OpenDocument Files
Anyone using OpenOffice "aqua"?
How 2 Convert .odt into .doc in java
find maching files in list
Java And OpenDocument Files