Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Doc(RTF) -> XML with Java

Posted on 2003-03-07
13
Medium Priority
?
420 Views
Last Modified: 2008-03-17
I need to convert a word document into xml using Java...any ideas?  I want to have total control over what in the word doc is converted...primarily i will want to ignore most of the data expect that which has been interested into fields by the user.  I will specify a special style for these fields in word, such as style = Company Name...and then i need something to convert this field into an xml tag company name.  Any one know of any open source projects in java that would help me with this task?

0
Comment
Question by:menreeq
  • 5
  • 3
  • 2
  • +3
13 Comments
 
LVL 86

Expert Comment

by:CEHJ
ID: 8090407
Listening...
0
 

Author Comment

by:menreeq
ID: 8090472
What does "Listening..." mean?
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 8090507
Waiting for comments
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 

Author Comment

by:menreeq
ID: 8090560
sweet
0
 
LVL 1

Expert Comment

by:shji1
ID: 8091365
Some source I found for reading RTF files. MAybe you will find it useful...

http://www.cs.umb.edu/~bill/java/jdk1.3/src/javax/swing/text/rtf/

Strangly enough, these classes are in the language, but I could not find them in the API....
I wonder
0
 
LVL 35

Expert Comment

by:girionis
ID: 8091686
 You can use Majix by IBM: http://www-106.ibm.com/developerworks/xml/library/x-tiprtf/ and you can download it from here: http://tetrasys.dhs.org/

  Hope it helps.
0
 
LVL 35

Expert Comment

by:girionis
ID: 8091691
> You can use Majix by IBM

  Sorry, it is by TetraSix and not by IBM. It's just the review of Majix on IBM's site.
0
 

Author Comment

by:menreeq
ID: 8091855
girionis, i have tried to use that software but it does not provide me with the flexibility that i require.  

What do you guys think about using macros in the word doc to some how capture the data in the form in a fashion that would allow me to easily recapture it when i need to process the form?  i have never ever used macros...nor do i know much about it.

shji1, i am going to look into your suggestion now.
0
 
LVL 35

Expert Comment

by:girionis
ID: 8091917
 Sorry menreeg I have never actually used ms word macros with java so I am unable to offer you anyhelp.

  Some more links that *might* be of interest to you though:

http://www.idealliance.org/papers/xmle02/dx_xmle02/papers/02-06-03/02-06-03.html
http://www.jguru.com/faq/view.jsp?EID=213149
http://www.rtf2fo.com/
0
 

Author Comment

by:menreeq
ID: 8116039
i don't think there is a good solution to my question, i am going to ask the admin to del it
0
 

Expert Comment

by:simonletter
ID: 8125523
I haven't work with OpenOffice before but it might help. http://www.openoffice.org. Download the ODK.

Have a look at OOo_1.0.2beta_Win32Intel_odk\OpenOffice.org1.0.2_Beta_SDK\examples\java\DocumentConverter\DocumentConverter.java

I think you'll need to start soffice or something that works as a UNO server whatever that is. So you'll write the client to get soffice to open the Word doc. I'm not sure what the API allows you to do.
0
 

Author Comment

by:menreeq
ID: 8125731
Well i found a good solution...I am using c# to access the word file where in less then 10 lines i was able to read each field and write my txt file...thanks for trying to help
0
 
LVL 5

Accepted Solution

by:
Netminder earned 0 total points
ID: 8125899
User resolved; points refunded and question closed.

Netminder
EE Admin
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues unde…
Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses
Course of the Month14 days, 9 hours left to enroll

577 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question