views:

21

answers:

1

I found some documentation about interop with OpenOffice using technologies like COM, but before delving in more deeply I wondered if anyone's worked on this kind of thing?

We have a need for the following, all wrapped up in a method call from a client PC (client talks to server using COM):

  1. Client sends a map of name/value pairs to a server app
  2. Server opens a Word template (.dot currently) file and looking up bookmarks using names from 1, replaces the text with values
  3. Server saves file as a Word .doc file

We were doing this using Word but some changes in Windows 2008 mean if you run without a desktop/interactive-user, Word won't start. It's obviously a big hack but we're looking for a quick solution rather than re-engineering due to time constraints... so I wondered if we can simply run up OO Writer on the server to do the same job? I know how ugly it all is so don't really need suggestions to create a brand new C# open XML SDK application.

Multiple simultaneous requests can be ruled out as a potential problem (or at least it's never been a problem using Word so unless OO is different it'll be ignored).

A: 

If you are thinking OpenOffice might help, you could use JODReports or Docmosis to help, though you'd need a small Java program to bridge from your C++ app (cmd line or whatever). These tools will let you control OpenOffice a little easier for doing your merge task than working with the OO API directly (hopefully a lower learning curve).

jowierun