Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Direct Access to Word document from Java

 
Paul Reedman
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have a problem - I need to update data in a table which exists in a MS Word document. (from Java)

I know about the Apache POI project, however it says that the MS Word interface is very immature.

I am wondering if anyone else has tried this and if so what API or tool did they use.

Thanks

Paul Reedman
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13062
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you get the Word Document in RTF format? That is supposed to be easier to interpret.
Bill
 
Paul Reedman
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes that might be possible.

Anyone know if (or where) the RTF format is documented..?
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13062
6
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've got one word for ya: Wotsit

You might use one of the Java parser generators for which an RTF grammar exists instead of rolling your own. Check out JavaCC, SableCC and Antlr.
 
Pradeep Kadambar
Ranch Hand
Posts: 148
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Look for the Jacob Project in sourceforge. This will allow bridging between java and COM objects.

It can be used to create, modify and save word, RTF documents.

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic